From 3b8324a46b34ed5dd5dff14d77de6cad13b16ce6 Mon Sep 17 00:00:00 2001 From: Guillaume Cottenceau Date: Thu, 22 Jan 2004 16:05:47 +0000 Subject: when checking for modules already loaded, be sure to check for the real name --- mdk-stage1/modules.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'mdk-stage1') diff --git a/mdk-stage1/modules.c b/mdk-stage1/modules.c index 20b7c5bb6..eb3ab9363 100644 --- a/mdk-stage1/modules.c +++ b/mdk-stage1/modules.c @@ -344,11 +344,12 @@ int module_already_present(const char * name) { FILE * f; int answ = 0; + const char * real_name = get_name_kernel_26_transition(name); if ((f = fopen("/proc/modules", "rb"))) { while (1) { char buf[500]; if (!fgets(buf, sizeof(buf), f)) break; - if (!strncmp(name, buf, strlen(name)) && buf[strlen(name)] == ' ') + if (!strncmp(real_name, buf, strlen(real_name)) && buf[strlen(real_name)] == ' ') answ = 1; } fclose(f); -- cgit v1.2.1