From: nasm-bot f. C. S. B. <cha...@in...> - 2020-05-05 06:57:32
|
Commit-ID: 7ee58d44e4df3f3097b9475dd0aafedecd428abd Gitweb: http://repo.or.cz/w/nasm.git?a=commitdiff;h=7ee58d44e4df3f3097b9475dd0aafedecd428abd Author: Chang S. Bae <cha...@in...> AuthorDate: Wed, 25 Mar 2020 15:13:21 -0700 Committer: Chang S. Bae <cha...@in...> CommitDate: Tue, 21 Apr 2020 21:12:01 +0000 preproc: Fix the token in expanding the macro-parameters The code looked to be unintentionally always nullifying the token pointer at first place in handling those macro-parameters. Remove it to avoid segfault. Fixes: de7acc3a46cb ("preproc: defer %00, %? and %?? expansion for nested macros, cleanups") Reported-by: C. Masloch <pu...@ul...> Link: https://bugzilla.nasm.us/show_bug.cgi?id=3392640 Signed-off-by: Chang S. Bae <cha...@in...> --- asm/preproc.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/asm/preproc.c b/asm/preproc.c index befe77e8..cf770026 100644 --- a/asm/preproc.c +++ b/asm/preproc.c @@ -4833,8 +4833,6 @@ static Token *expand_mmac_params(Token * tline) unsigned long n; char *ep; - text = NULL; - n = strtoul(tok_text(t) + 2, &ep, 10); if (unlikely(*ep)) goto invalid; |