From 1cdb4f411c123a1f7402c9efbe46b3b05c3d94a1 Mon Sep 17 00:00:00 2001 From: Guillaume Cottenceau Date: Wed, 3 Jul 2002 18:38:05 +0000 Subject: compile with -W --- mdk-stage1/modules.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'mdk-stage1/modules.c') diff --git a/mdk-stage1/modules.c b/mdk-stage1/modules.c index e2c06eebc..1fe1cd42a 100644 --- a/mdk-stage1/modules.c +++ b/mdk-stage1/modules.c @@ -95,7 +95,7 @@ static int load_modules_dependencies(void) fstat(fd, &s); buf = alloca(s.st_size + 1); - if (read(fd, buf, s.st_size) != s.st_size) { + if (read(fd, buf, s.st_size) != (ssize_t)s.st_size) { log_perror(deps_file); return -1; } @@ -190,7 +190,7 @@ static void add_modules_conf(char * str) return; } - if (write(fd, data, strlen(data) + 1) != strlen(data) + 1) + if (write(fd, data, strlen(data) + 1) != (ssize_t) (strlen(data) + 1)) log_perror(str); close(fd); @@ -239,7 +239,11 @@ static enum insmod_return insmod_with_deps(const char * mod_name, char * options } +#ifndef DISABLE_NETWORK enum insmod_return my_insmod(const char * mod_name, enum driver_type type, char * options) +#else +enum insmod_return my_insmod(const char * mod_name, enum driver_type type __attribute__ ((unused)), char * options) +#endif { int i; #ifndef DISABLE_NETWORK -- cgit v1.2.1