diff options
author | Hendiadyoin1 <leon2002.la@gmail.com> | 2021-10-24 23:31:49 +0200 |
---|---|---|
committer | Linus Groh <mail@linusgroh.de> | 2021-11-16 00:49:48 +0000 |
commit | 153312326371aca3537cca15b9d61fdc967fa56b (patch) | |
tree | 431c512f6384cccc66d4f2492566f499311fc527 /Userland/DevTools | |
parent | 134f43ba12488201fab7cf43fbf525040fecbb57 (diff) | |
download | serenity-153312326371aca3537cca15b9d61fdc967fa56b.zip |
Profiler: Stop disassembly on invalid instructions
Diffstat (limited to 'Userland/DevTools')
-rw-r--r-- | Userland/DevTools/Profiler/DisassemblyModel.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Userland/DevTools/Profiler/DisassemblyModel.cpp b/Userland/DevTools/Profiler/DisassemblyModel.cpp index 4e6dd9cb7c..749377b38c 100644 --- a/Userland/DevTools/Profiler/DisassemblyModel.cpp +++ b/Userland/DevTools/Profiler/DisassemblyModel.cpp @@ -123,7 +123,7 @@ DisassemblyModel::DisassemblyModel(Profile& profile, ProfileNode& node) break; auto insn = disassembler.next(); - if (!insn.has_value()) + if (!insn.has_value() || !insn.value().is_valid()) break; FlatPtr address_in_profiled_program = node.address() + offset_into_symbol; |