From 0a95935e46a35ffdd549ef774d6f419d9990a9f3 Mon Sep 17 00:00:00 2001 From: rlar Date: Sun, 5 Mar 2017 13:46:40 +0100 Subject: [PATCH] inp2m.c, #4/15b, unify code slightly --- src/spicelib/parser/inp2m.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/spicelib/parser/inp2m.c b/src/spicelib/parser/inp2m.c index 60a21080a..d2f2c184d 100644 --- a/src/spicelib/parser/inp2m.c +++ b/src/spicelib/parser/inp2m.c @@ -32,6 +32,7 @@ INP2M(CKTcircuit *ckt, INPtables *tab, card *current) char *nname5; /* the fifth node's name */ char *nname6; /* the sixt node's name */ char *nname7; /* the seventh node's name */ + char *nname8; char *save; /* saj - used to save the posn of the start of the parameters if the model is a mosfet*/ CKTnode *node1; /* the first node's node pointer */ @@ -102,9 +103,9 @@ INP2M(CKTcircuit *ckt, INPtables *tab, card *current) if (!thismodel) { nodeflag = 7; - INPgetTok(&line, &model, 1); + INPgetTok(&line, &nname8, 1); - err_msg = INPgetMod(ckt, model, &thismodel, tab); + err_msg = INPgetMod(ckt, nname8, &thismodel, tab); tfree(err_msg); if (thismodel) { @@ -120,6 +121,7 @@ INP2M(CKTcircuit *ckt, INPtables *tab, card *current) INPtermInsert(ckt, &nname5, tab, &node5); INPtermInsert(ckt, &nname6, tab, &node6); INPtermInsert(ckt, &nname7, tab, &node7); + model = nname8; } } else {