nupa_subcktcall(), avoid `jp' pointing beyond end of string

The skip whitespace loop in the following line shall
  safely swallow the delimiting space instead
This commit is contained in:
rlar 2017-11-25 19:09:53 +01:00
parent bb9689139b
commit 437f92385a
1 changed files with 1 additions and 1 deletions

View File

@ -1607,7 +1607,7 @@ nupa_subcktcall(dico_t *dico, char *s, char * const x, char * const inst_name)
char *p_subname = search_isolated_identifier(t_p, spice_dstring_value(&subname));
if (p_subname) {
char *jp = p_subname + spice_dstring_length(&subname) + 1; /* 1st position of arglist */
char *jp = p_subname + spice_dstring_length(&subname); /* 1st position of arglist */
while ((jp < ls_ptr) && ((*jp <= ' ') || (*jp == ',')))
jp++;