From abd5931184c49fffc62efeadb2795ccbb86bce05 Mon Sep 17 00:00:00 2001 From: Andreas Kling Date: Wed, 27 Mar 2019 01:29:49 +0100 Subject: [PATCH] Kernel: Print an error when trying to load an incompatible ELF image. --- Kernel/ELFImage.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Kernel/ELFImage.cpp b/Kernel/ELFImage.cpp index 51d9975883..9e86036540 100644 --- a/Kernel/ELFImage.cpp +++ b/Kernel/ELFImage.cpp @@ -91,8 +91,10 @@ unsigned ELFImage::program_header_count() const bool ELFImage::parse() { // We only support i386. - if (header().e_machine != 3) + if (header().e_machine != 3) { + kprintf("ELFImage::parse(): e_machine=%u not supported!\n"); return false; + } // First locate the string tables. for (unsigned i = 0; i < section_count(); ++i) {