From a9eb96e1648b0599d02dc38cc35c58981f5054ed Mon Sep 17 00:00:00 2001 From: rlar Date: Sat, 5 May 2012 22:20:36 +0200 Subject: [PATCH] avoid `ambiguous else' Warning --- src/frontend/inpcom.c | 30 ++++++++++++------------------ 1 file changed, 12 insertions(+), 18 deletions(-) diff --git a/src/frontend/inpcom.c b/src/frontend/inpcom.c index 47c52f203..750dd44ff 100644 --- a/src/frontend/inpcom.c +++ b/src/frontend/inpcom.c @@ -4372,15 +4372,13 @@ static void inp_compat(struct line *deck) else if ( *curr_line == 'r' ) { if ((!strstr(curr_line, "v(")) && (!strstr(curr_line, "i(")) && (!strstr(curr_line, "temper")) && (!strstr(curr_line, "hertz")) - && (!strstr(curr_line, "time"))) + && (!strstr(curr_line, "time"))) { /* no handling in B-Source, so we have to prepare ternary fcn for numparam */ - if ( strstr( curr_line, "?" ) && strstr( curr_line, ":" ) ) { + if ( strstr( curr_line, "?" ) && strstr( curr_line, ":" ) ) card->li_line = inp_fix_ternary_operator_str( curr_line, TRUE ); - continue; - } - else - continue; + continue; + } cut_line = curr_line; /* make BRxxx pos neg I = V(pos, neg)/{equation}*/ title_tok = gettok(&cut_line); @@ -4459,15 +4457,13 @@ static void inp_compat(struct line *deck) else if ( *curr_line == 'c' ) { if ((!strstr(curr_line, "v(")) && (!strstr(curr_line, "i(")) && (!strstr(curr_line, "temper")) && (!strstr(curr_line, "hertz")) - && (!strstr(curr_line, "time"))) + && (!strstr(curr_line, "time"))) { /* no handling in B-Source, so we have to prepare ternary fcn for numparam */ - if ( strstr( curr_line, "?" ) && strstr( curr_line, ":" ) ) { + if ( strstr( curr_line, "?" ) && strstr( curr_line, ":" ) ) card->li_line = inp_fix_ternary_operator_str( curr_line, TRUE ); - continue; - } - else - continue; + continue; + } cut_line = curr_line; /* title and nodes */ title_tok = gettok(&cut_line); @@ -4567,15 +4563,13 @@ static void inp_compat(struct line *deck) else if ( *curr_line == 'l' ) { if ((!strstr(curr_line, "v(")) && (!strstr(curr_line, "i(")) && (!strstr(curr_line, "temper")) && (!strstr(curr_line, "hertz")) - && (!strstr(curr_line, "time"))) + && (!strstr(curr_line, "time"))) { /* no handling in B-Source, so we have to prepare ternary fcn for numparam */ - if ( strstr( curr_line, "?" ) && strstr( curr_line, ":" ) ) { + if ( strstr( curr_line, "?" ) && strstr( curr_line, ":" ) ) card->li_line = inp_fix_ternary_operator_str( curr_line, TRUE ); - continue; - } - else - continue; + continue; + } cut_line = curr_line; /* title and nodes */ title_tok = gettok(&cut_line);