aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorH. Peter Anvin <hpa@zytor.com>2019-09-12 18:34:14 -0700
committerH. Peter Anvin <hpa@zytor.com>2019-09-12 18:34:14 -0700
commit14f0328aa18b6aeb8b74dc6f73369a992d04ff30 (patch)
treed2b2563e62106e0c30b312fbb10dd0f2e58e1490
parentd626f355f6d3eb158968945b64d08411b259153b (diff)
downloadnasm-14f0328aa18b6aeb8b74dc6f73369a992d04ff30.tar.gz
nasm-14f0328aa18b6aeb8b74dc6f73369a992d04ff30.tar.xz
nasm-14f0328aa18b6aeb8b74dc6f73369a992d04ff30.zip
eval: don't try to poke *opflags if opflags is NULL
While changing this code around to not do redundant lookups, dropped this NULL pointer check. Oops. Signed-off-by: H. Peter Anvin (Intel) <hpa@zytor.com>
-rw-r--r--asm/eval.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/asm/eval.c b/asm/eval.c
index c99ee11c..0dd7e61a 100644
--- a/asm/eval.c
+++ b/asm/eval.c
@@ -988,7 +988,8 @@ static expr *expr6(void)
label_seg = NO_SEG;
label_ofs = 1;
} else if (is_extern(ltype)) {
- *opflags |= OPFLAG_EXTERN;
+ if (opflags)
+ *opflags |= OPFLAG_EXTERN;
}
}
addtotemp(type, label_ofs);