Fixed out of bounds error in writing section load addresses

This commit is contained in:
Mr-Wiseguy 2023-02-06 22:13:06 -05:00
parent 3f73f99cc6
commit fedeb72451
2 changed files with 7 additions and 5 deletions

View file

@ -1131,6 +1131,8 @@ int main(int argc, char** argv) {
section_load_table += "};\n";
fmt::print(overlay_file, "{}", section_load_table);
fmt::print(overlay_file, "const size_t num_sections = {};\n", context.sections.size());
}
return 0;