diff mbox

[1/3] elf-loader: warn about invalid endianess

Message ID 20170623164557.11636-2-f4bug@amsat.org
State Accepted, archived
Headers show

Commit Message

Philippe Mathieu-Daudé June 23, 2017, 4:45 p.m. UTC
fprintf(stderr) is how errors are reported in this file.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 hw/core/loader.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Michael Tokarev June 27, 2017, 1:29 p.m. UTC | #1
23.06.2017 19:45, Philippe Mathieu-Daudé wrote:
> fprintf(stderr) is how errors are reported in this file.

Applied to -trivial (with typo fix), thanks!

/mjt
diff mbox

Patch

diff --git a/hw/core/loader.c b/hw/core/loader.c
index f72930ca4a..094f24627f 100644
--- a/hw/core/loader.c
+++ b/hw/core/loader.c
@@ -478,6 +478,7 @@  int load_elf_ram(const char *filename,
     }
 
     if (target_data_order != e_ident[EI_DATA]) {
+        fprintf(stderr, "%s: wrong endianess\n", filename);
         ret = ELF_LOAD_WRONG_ENDIAN;
         goto fail;
     }