mirror of
https://github.com/netwide-assembler/nasm
synced 2026-08-26 16:23:04 -04:00
Free EOT_DB_STRING_FREE in cleanup_insn()
Free EOT_DB_STRING_FREE data in cleanup_insn(), which is where we free all the other extop data.
This commit is contained in:
parent
a0b91037e2
commit
2aa77394b7
2 changed files with 4 additions and 5 deletions
|
|
@ -349,8 +349,6 @@ int64_t assemble(int32_t segment, int64_t offset, int bits, uint32_t cp,
|
|||
OUT_RAWDATA, align, NO_SEG, NO_SEG);
|
||||
}
|
||||
offset += e->stringlen + align;
|
||||
if (e->type == EOT_DB_STRING_FREE)
|
||||
nasm_free(e->stringval);
|
||||
}
|
||||
}
|
||||
if (t > 0 && t == instruction->times - 1) {
|
||||
|
|
|
|||
7
parser.c
7
parser.c
|
|
@ -947,9 +947,10 @@ void cleanup_insn(insn * i)
|
|||
{
|
||||
extop *e;
|
||||
|
||||
while (i->eops) {
|
||||
e = i->eops;
|
||||
i->eops = i->eops->next;
|
||||
while ((e = i->eops)) {
|
||||
i->eops = e->next;
|
||||
if (e->type == EOT_DB_STRING_FREE)
|
||||
nasm_free(e->stringval);
|
||||
nasm_free(e);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue