mirror of
https://github.com/gbdev/rgbds.git
synced 2025-11-20 10:12:06 +00:00
Use std::deque for symbol lists
Also fix a memory leak that this reveals
This commit is contained in:
@@ -422,6 +422,10 @@ int main(int argc, char *argv[])
|
||||
if (isDmgMode)
|
||||
sectionTypeInfo[SECTTYPE_VRAM].lastBank = 0;
|
||||
|
||||
// Do cleanup before quitting, though.
|
||||
// Mostly here to please tools such as `valgrind` so actual errors can be seen
|
||||
atexit(obj_Cleanup);
|
||||
|
||||
// Read all object files first,
|
||||
for (obj_Setup(argc - curArgIndex); curArgIndex < argc; curArgIndex++)
|
||||
obj_ReadFile(argv[curArgIndex], argc - curArgIndex - 1);
|
||||
@@ -450,8 +454,4 @@ int main(int argc, char *argv[])
|
||||
if (nbErrors != 0)
|
||||
reportErrors();
|
||||
out_WriteFiles();
|
||||
|
||||
// Do cleanup before quitting, though.
|
||||
// Mostly here to please tools such as `valgrind` so actual errors can be seen
|
||||
obj_Cleanup();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user