From 5505120148cf3cf07bb500b2fd4a3444e1aa88e7 Mon Sep 17 00:00:00 2001 From: Luke Street Date: Sun, 11 May 2025 22:15:02 -0600 Subject: [PATCH] Fix padding symbols on REL section boundaries Regression introduced in 6819a8b --- Cargo.lock | 2 +- Cargo.toml | 2 +- src/util/split.rs | 1 + 3 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 7a08434..ec9ca26 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -348,7 +348,7 @@ dependencies = [ [[package]] name = "decomp-toolkit" -version = "1.5.0" +version = "1.5.1" dependencies = [ "aes", "anyhow", diff --git a/Cargo.toml b/Cargo.toml index 685470d..dade88b 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -3,7 +3,7 @@ name = "decomp-toolkit" description = "Yet another GameCube/Wii decompilation toolkit." authors = ["Luke Street "] license = "MIT OR Apache-2.0" -version = "1.5.0" +version = "1.5.1" edition = "2021" publish = false repository = "https://github.com/encounter/decomp-toolkit" diff --git a/src/util/split.rs b/src/util/split.rs index 9e4fdd8..269b902 100644 --- a/src/util/split.rs +++ b/src/util/split.rs @@ -561,6 +561,7 @@ fn add_padding_symbols(obj: &mut ObjInfo) -> Result<()> { { let next_split_address = splits .peek() + .filter(|(i, _, _, _)| *i == section_index) .map(|(_, _, addr, _)| *addr as u64) .unwrap_or(section.address + section.size); let next_symbol_address = obj