From 2be3776f348a8a369db67d30bf7c54a46333cef2 Mon Sep 17 00:00:00 2001 From: mintsuki Date: Tue, 7 Dec 2021 11:53:17 +0100 Subject: [PATCH] linux: Ensure loading message shows up before fopen() for modules --- stage23/protos/linux.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/stage23/protos/linux.c b/stage23/protos/linux.c index d97a4f83..d4b3a123 100644 --- a/stage23/protos/linux.c +++ b/stage23/protos/linux.c @@ -471,12 +471,12 @@ bool linux_load(char *config, char *cmdline) { if (module_path == NULL) break; + print("linux: Loading module `%s`...\n", module_path); + struct file_handle *module; if ((module = uri_open(module_path)) == NULL) panic("linux: Could not open `%s`", module_path); - print("linux: Loading module `%s`...\n", module_path); - fread(module, (void *)_modules_mem_base, 0, module->size); _modules_mem_base += module->size;