diff options
author | H. Peter Anvin, Intel <h.peter.anvin@intel.com> | 2018-06-25 13:11:01 -0700 |
---|---|---|
committer | H. Peter Anvin, Intel <h.peter.anvin@intel.com> | 2018-06-25 13:11:01 -0700 |
commit | 4fb2acc0d3ff6bdb0d5dbcb6368ac1a524186ced (patch) | |
tree | b486ffce5a24819917af7076f80411e41b23b788 | |
parent | 2139874de255afe69533d59724896a2627f9a62f (diff) | |
download | nasm-4fb2acc0d3ff6bdb0d5dbcb6368ac1a524186ced.tar.gz |
labels: if we have overridden EXTERN, don't call define_label()
If we have overridden EXTERN, then we should not call define_label()
on it again. Return a fail status from declare_label(), indicating
that the type declaration failed, but of course we don't print an
error message.
Signed-off-by: H. Peter Anvin (Intel) <hpa@zytor.com>
-rw-r--r-- | asm/labels.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/asm/labels.c b/asm/labels.c index 0f9f17d8..1b93348c 100644 --- a/asm/labels.c +++ b/asm/labels.c @@ -398,7 +398,7 @@ static bool declare_label_lptr(union label *lptr, type == LBL_EXTERN) { if (!lptr->defn.special) lptr->defn.special = perm_copy(special); - return true; + return false; /* Don't call define_label() after this! */ } nasm_error(ERR_NONFATAL, "symbol `%s' declared both as %s and %s", |