mirror of
https://github.com/netwide-assembler/nasm.git
synced 2025-10-10 00:25:06 -04:00
codeview: Don't treat labels starting with .. as local labels
For local labels, starting with '.', the label name is concatenated with the previous non-local label to produce a label that can be accessed from elsewhere. This is the name we want to generate debug info for. Labels starting with ".." are special and shouldn't be concatenated. Fix Bugzilla #3392342 Signed-off-by: Jim Kukunas <james.t.kukunas@linux.intel.com>
This commit is contained in:
@@ -215,7 +215,7 @@ static void cv8_deflabel(char *name, int32_t segment, int64_t offset,
|
|||||||
sym->typeindex = 0;
|
sym->typeindex = 0;
|
||||||
|
|
||||||
/* handle local labels */
|
/* handle local labels */
|
||||||
if (name[0] == '.' && cv8_state.last_sym != NULL) {
|
if (name[0] == '.' && name[1] != '.' && cv8_state.last_sym != NULL) {
|
||||||
len = strlen(cv8_state.last_sym->name) + strlen(name);
|
len = strlen(cv8_state.last_sym->name) + strlen(name);
|
||||||
sym->name = nasm_malloc(len + 1);
|
sym->name = nasm_malloc(len + 1);
|
||||||
ret = snprintf(sym->name, len + 1, "%s%s",
|
ret = snprintf(sym->name, len + 1, "%s%s",
|
||||||
|
Reference in New Issue
Block a user