don't hang when processing \{N} escape sequences and fix a comment

This commit is contained in:
Bill Currie 2010-01-13 06:21:29 +00:00 committed by Jeff Teunissen
parent 15c46c3b27
commit 36fe939ea5
2 changed files with 2 additions and 2 deletions

View file

@ -1020,7 +1020,7 @@ int PR_RelocateBuiltins (progs_t *pr);
temporary strings, as well as mutable strings using dstrings. temporary strings, as well as mutable strings using dstrings.
Permanent strings are either supplied by the progs (+ve string index) or Permanent strings are either supplied by the progs (+ve string index) or
set the the main program using PR_SetString(). Permanent strings can never set by the main program using PR_SetString(). Permanent strings can never
be altered and will exist until the next progs load. be altered and will exist until the next progs load.
Dynamic strings can be freed at any time, but not altered. Dynamic strings can be freed at any time, but not altered.

View file

@ -605,7 +605,7 @@ make_string (char *token, char **end)
while (*token && *token != '}' while (*token && *token != '}'
&& isdigit ((unsigned char)*token)) { && isdigit ((unsigned char)*token)) {
c *= 10; c *= 10;
c += *token - '0'; c += *token++ - '0';
} }
if (!*token) if (!*token)
error (0, "EOF inside quote"); error (0, "EOF inside quote");