mirror of
https://git.code.sf.net/p/ngspice/ngspice
synced 2026-09-04 03:03:32 +02:00
bug #408: prevent invalid data or crash by not reading beyond end of string
This commit is contained in:
@@ -44,7 +44,8 @@ cp_bquote(wordlist *wlist)
|
||||
*s++ = *t++;
|
||||
/* What the heck, let "echo `foo" work... */
|
||||
*s = '\0';
|
||||
t++; /* Get past the second ` */
|
||||
if (*t != '\0')
|
||||
t++; /* Get past the second ` */
|
||||
if ((nwl = backeval(buf)) == NULL) {
|
||||
wlist->wl_word = NULL;
|
||||
return (wlist);
|
||||
|
||||
Reference in New Issue
Block a user