Browse Source

getword(), substitute s = s - 1

pre-master-46
rlar 10 years ago
parent
commit
d6801c0cf1
  1. 10
      src/frontend/numparam/xpressn.c

10
src/frontend/numparam/xpressn.c

@ -1326,12 +1326,12 @@ getword(const char *s, const char * const s_end, SPICE_DSTRINGPTR tstr_p)
spice_dstring_reinit(tstr_p);
while ((s - 1 < s_end) && (alfa(s[-1]) || isdigit_c(s[-1]))) {
cadd(tstr_p, toupper_c(s[-1]));
s++;
}
s--;
return s;
while ((s < s_end) && (alfa(*s) || isdigit_c(*s)))
cadd(tstr_p, toupper_c(*s++));
return s + 1;
}

Loading…
Cancel
Save