From d647a84e66b2dcc714154078266a98fd5967d258 Mon Sep 17 00:00:00 2001 From: rlar Date: Wed, 22 Nov 2017 21:56:06 +0100 Subject: [PATCH] findsubname(), just truncate it --- src/frontend/numparam/spicenum.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/frontend/numparam/spicenum.c b/src/frontend/numparam/spicenum.c index 49e383a8d..87d3ac596 100644 --- a/src/frontend/numparam/spicenum.c +++ b/src/frontend/numparam/spicenum.c @@ -193,8 +193,7 @@ findsubname(dico_t *dico, SPICE_DSTRINGPTR dstr_p) cadd(&name, toupper_c(*t)); entry = entrynb(dico, spice_dstring_value(&name)); if (entry && (entry->tp == NUPA_SUBCKT)) { - if (p_end < ls_ptr) - pscopy(dstr_p, s, 0, (int) (p_end - s)); + spice_dstring_setlength(dstr_p, (int) (p_end - s)); return; } }