Skip to content

Commit 6c8b0a3

Browse files
committed
[lldb] Fix SBTarget::ReadInstruction
The disassemblyBytes parameters are not ordered correctly and crashes when the read instruction is called
1 parent 6f34d03 commit 6c8b0a3

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

lldb/source/API/SBTarget.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2021,9 +2021,9 @@ lldb::SBInstructionList SBTarget::ReadInstructions(lldb::SBAddress base_addr,
20212021
error, force_live_memory, &load_addr);
20222022
const bool data_from_file = load_addr == LLDB_INVALID_ADDRESS;
20232023
sb_instructions.SetDisassembler(Disassembler::DisassembleBytes(
2024-
target_sp->GetArchitecture(), nullptr, target_sp->GetDisassemblyCPU(),
2025-
target_sp->GetDisassemblyFeatures(), flavor_string, *addr_ptr,
2026-
data.GetBytes(), bytes_read, count, data_from_file));
2024+
target_sp->GetArchitecture(), nullptr, flavor_string,
2025+
target_sp->GetDisassemblyCPU(), target_sp->GetDisassemblyFeatures(),
2026+
*addr_ptr, data.GetBytes(), bytes_read, count, data_from_file));
20272027
}
20282028
}
20292029

0 commit comments

Comments
 (0)