summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGuillaume Cottenceau <gc@mandriva.com>2004-01-22 16:05:47 +0000
committerGuillaume Cottenceau <gc@mandriva.com>2004-01-22 16:05:47 +0000
commit3b8324a46b34ed5dd5dff14d77de6cad13b16ce6 (patch)
treeb8231d2aa9a9cbf38ac0b6b894988252b42f7caf
parent6984cca61ece007de3b292278d5787d728e54c6b (diff)
downloaddrakx-backup-do-not-use-3b8324a46b34ed5dd5dff14d77de6cad13b16ce6.tar
drakx-backup-do-not-use-3b8324a46b34ed5dd5dff14d77de6cad13b16ce6.tar.gz
drakx-backup-do-not-use-3b8324a46b34ed5dd5dff14d77de6cad13b16ce6.tar.bz2
drakx-backup-do-not-use-3b8324a46b34ed5dd5dff14d77de6cad13b16ce6.tar.xz
drakx-backup-do-not-use-3b8324a46b34ed5dd5dff14d77de6cad13b16ce6.zip
when checking for modules already loaded, be sure to check for the real name
-rw-r--r--mdk-stage1/modules.c3
1 files changed, 2 insertions, 1 deletions
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);