1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 03:48:13 +00:00

ProfileViewer: Fix opening the kernel image

The kernel image is now at /boot/Kernel (not /boot/kernel), so adjust
the paths accordingly.
This commit is contained in:
Sergey Bugaev 2020-05-15 18:20:11 +03:00 committed by Andreas Kling
parent 6fcdfe1169
commit b8fef58c0c
2 changed files with 2 additions and 2 deletions

View file

@ -72,7 +72,7 @@ DisassemblyModel::DisassemblyModel(Profile& profile, ProfileNode& node)
{ {
String path; String path;
if (m_node.address() >= 0xc0000000) if (m_node.address() >= 0xc0000000)
path = "/boot/kernel"; path = "/boot/Kernel";
else else
path = profile.executable_path(); path = profile.executable_path();
m_file = make<MappedFile>(path); m_file = make<MappedFile>(path);

View file

@ -188,7 +188,7 @@ OwnPtr<Profile> Profile::load_from_perfcore_file(const StringView& path)
auto elf_loader = ELF::Loader::create(static_cast<const u8*>(elf_file.data()), elf_file.size()); auto elf_loader = ELF::Loader::create(static_cast<const u8*>(elf_file.data()), elf_file.size());
MappedFile kernel_elf_file("/boot/kernel"); MappedFile kernel_elf_file("/boot/Kernel");
RefPtr<ELF::Loader> kernel_elf_loader; RefPtr<ELF::Loader> kernel_elf_loader;
if (kernel_elf_file.is_valid()) if (kernel_elf_file.is_valid())
kernel_elf_loader = ELF::Loader::create(static_cast<const u8*>(kernel_elf_file.data()), kernel_elf_file.size()); kernel_elf_loader = ELF::Loader::create(static_cast<const u8*>(kernel_elf_file.data()), kernel_elf_file.size());