mirror of
https://github.com/open-simh/simtools.git
synced 2026-05-04 06:58:32 +00:00
Put code where it belongs.
This commit is contained in:
@@ -693,8 +693,15 @@ void write_globals(
|
|||||||
SYMBOL_ITER sym_iter;
|
SYMBOL_ITER sym_iter;
|
||||||
int isect;
|
int isect;
|
||||||
|
|
||||||
if (obj == NULL)
|
if (obj == NULL) {
|
||||||
return; /* Nothing to do if no OBJ file. */
|
for (isect = 0; isect < sector; isect++) {
|
||||||
|
psect = sections[isect];
|
||||||
|
|
||||||
|
psect->sector = isect; /* Assign it a sector */
|
||||||
|
psect->pc = 0; /* Reset its PC for second pass */
|
||||||
|
}
|
||||||
|
return; /* Nothing more to do if no OBJ file. */
|
||||||
|
}
|
||||||
|
|
||||||
gsd_init(&gsd, obj);
|
gsd_init(&gsd, obj);
|
||||||
|
|
||||||
|
|||||||
@@ -353,13 +353,6 @@ int main(
|
|||||||
stack_push(&stack, str);
|
stack_push(&stack, str);
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
|
||||||
* Reset dot in all sections. write_globals() only does it
|
|
||||||
* if there is an object file.
|
|
||||||
*/
|
|
||||||
for (i = 0; i < sector; i++) {
|
|
||||||
sections[i]->pc = 0;
|
|
||||||
}
|
|
||||||
DOT = 0;
|
DOT = 0;
|
||||||
|
|
||||||
current_pc->section = &blank_section;
|
current_pc->section = &blank_section;
|
||||||
|
|||||||
Reference in New Issue
Block a user