From f88f9f8e2e9a3e480ec9d440bd82829b9ef2dfc9 Mon Sep 17 00:00:00 2001 From: stefan schippers Date: Wed, 10 Apr 2024 12:08:09 +0200 Subject: [PATCH] do not exit is calling xschem with a non existent file on cmdline --- src/xinit.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/xinit.c b/src/xinit.c index bbfe58cd..b330eed5 100644 --- a/src/xinit.c +++ b/src/xinit.c @@ -2846,10 +2846,10 @@ int Tcl_AppInit(Tcl_Interp *inter) /* if cli_opt_do_netlist=1 call load_schematic with 'reset_undo=0' avoiding call to tcl is_xschem_file that could change xctx->netlist_type to symbol */ file_loaded = load_schematic(1, f, !cli_opt_do_netlist, 1); - if(!file_loaded) tcleval("exit 1"); + if(cli_opt_do_netlist) if(!file_loaded) tcleval("exit 1"); if(cli_opt_do_netlist) set_modify(-1); /* set tab/window title */ tclvareval("update_recent_file {", f, "}", NULL); - } else /* if(!cli_opt_tcl_script[0]) */ + } else /* if(!cli_opt_filename[0]) */ { char * tmp; char fname[PATH_MAX];