From: nasm-bot f. C. G. <gor...@gm...> - 2019-03-16 20:21:29
|
Commit-ID: 982186a1a3139763f2aa2710b32236009f64270d Gitweb: http://repo.or.cz/w/nasm.git?a=commitdiff;h=982186a1a3139763f2aa2710b32236009f64270d Author: Cyrill Gorcunov <gor...@gm...> AuthorDate: Sat, 16 Mar 2019 23:05:50 +0300 Committer: Cyrill Gorcunov <gor...@gm...> CommitDate: Sat, 16 Mar 2019 23:19:12 +0300 preproc: Fix nil dereference on error paths https://bugzilla.nasm.us/show_bug.cgi?id=3392562 Signed-off-by: Cyrill Gorcunov <gor...@gm...> --- asm/preproc.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/asm/preproc.c b/asm/preproc.c index 833a3d47..5f6b0a62 100644 --- a/asm/preproc.c +++ b/asm/preproc.c @@ -4198,7 +4198,8 @@ again: do { t = tline->next; while (tok_type_(t, TOK_SMAC_END)) { - t->a.mac->in_progress = false; + if (t->a.mac) + t->a.mac->in_progress = false; t->text = NULL; t = tline->next = delete_Token(t); } @@ -4228,7 +4229,8 @@ again: */ t = tline->next; while (tok_type_(t, TOK_SMAC_END)) { - t->a.mac->in_progress = false; + if (t->a.mac) + t->a.mac->in_progress = false; t->text = NULL; t = tline->next = delete_Token(t); } |