From 9887a2fb2bfd7c97aaf14f90752ed32f589b88f3 Mon Sep 17 00:00:00 2001 From: rlar Date: Sat, 2 Jul 2011 20:19:21 +0000 Subject: [PATCH] main.c, emphasize the SETJMP wrapper in ngspice and ngnutmeg --- src/main.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/main.c b/src/main.c index eb232cbac..e4bdd0f8e 100644 --- a/src/main.c +++ b/src/main.c @@ -1115,6 +1115,9 @@ main(int argc, char **argv) } + +#ifdef SIMULATOR + /* Pass 2 -- get the filenames. If we are spice, then this means * build a circuit for this file. If this is in server mode, don't * process any of these args. */ @@ -1125,8 +1128,6 @@ main(int argc, char **argv) cp_interactive = FALSE; err = 0; -#ifdef SIMULATOR - #ifdef FastRand // initialization and seed for FastNorm Gaussian random generator { @@ -1305,6 +1306,12 @@ evl: #else /* ~ SIMULATOR */ + if (SETJMP(jbuf, 1)) + goto evl; + + cp_interactive = FALSE; + err = 0; + if (ft_nutmeg && gdata) { if (optind < argc) while (optind < argc)