Skip to content

Commit 7fcd771

Browse files
committed
fixed a crash
1 parent d13e817 commit 7fcd771

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

out

Whitespace-only changes.

src/as4.c

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -531,11 +531,14 @@ int main(int argc, char **argv)
531531
{
532532
address = 0;
533533
}
534-
/* Get the address location. */
535-
/* If it's just a number after the instruction, that will be returned with the base address added to it. */
536-
/* If it's a yet undeclared label, 65535 (UNKNOWNADDR) is returned. The instruction will be modified when the label is declared. */
537-
/* If it's an already declared label return the address relative to the base address. */
538-
address = findlabel(&unknownlabels, &labels, tokens, numlabels, &numunknownlabels, bits, INST);
534+
else
535+
{
536+
/* Get the address location. */
537+
/* If it's just a number after the instruction, that will be returned with the base address added to it. */
538+
/* If it's a yet undeclared label, 65535 (UNKNOWNADDR) is returned. The instruction will be modified when the label is declared. */
539+
/* If it's an already declared label return the address relative to the base address. */
540+
address = findlabel(&unknownlabels, &labels, tokens, numlabels, &numunknownlabels, bits, INST);
541+
}
539542
/* Add this to the output buffer. */
540543
addinst(outbuf, NOP, address, &bits, &bytes);
541544
}

src/out

212 Bytes
Binary file not shown.

0 commit comments

Comments
 (0)