From: nasm-bot f. C. G. <gor...@gm...> - 2017-10-22 07:54:28
|
Commit-ID: 3144e84add8b152cc7a71e44617ce6f21daa4ba3 Gitweb: http://repo.or.cz/w/nasm.git?a=commitdiff;h=3144e84add8b152cc7a71e44617ce6f21daa4ba3 Author: Cyrill Gorcunov <gor...@gm...> AuthorDate: Sun, 22 Oct 2017 10:50:55 +0300 Committer: Cyrill Gorcunov <gor...@gm...> CommitDate: Sun, 22 Oct 2017 10:50:55 +0300 preproc: Don't access offsting byte on unterminated strings https://bugzilla.nasm.us/show_bug.cgi?id=3392446 Signed-off-by: Cyrill Gorcunov <gor...@gm...> --- asm/preproc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/asm/preproc.c b/asm/preproc.c index a8388bc..7b1e2bf 100644 --- a/asm/preproc.c +++ b/asm/preproc.c @@ -948,7 +948,9 @@ static Token *tokenize(char *line) case '\'': case '\"': case '`': - p = nasm_skip_string(p - 1) + 1; + p = nasm_skip_string(p - 1); + if (*p) + p++; break; default: break; |