diff options
Diffstat (limited to 'modutils/lsmod.c')
-rw-r--r-- | modutils/lsmod.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/modutils/lsmod.c b/modutils/lsmod.c index 5e37923a9..3f237039e 100644 --- a/modutils/lsmod.c +++ b/modutils/lsmod.c | |||
@@ -28,7 +28,7 @@ static void check_tainted(void) | |||
28 | FILE *f; | 28 | FILE *f; |
29 | 29 | ||
30 | tainted = 0; | 30 | tainted = 0; |
31 | f = fopen(TAINT_FILENAME, "r"); | 31 | f = fopen_for_read(TAINT_FILENAME); |
32 | if (f) { | 32 | if (f) { |
33 | fscanf(f, "%d", &tainted); | 33 | fscanf(f, "%d", &tainted); |
34 | fclose(f); | 34 | fclose(f); |
@@ -145,7 +145,7 @@ int lsmod_main(int argc UNUSED_PARAM, char **argv UNUSED_PARAM) | |||
145 | int lsmod_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; | 145 | int lsmod_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE; |
146 | int lsmod_main(int argc UNUSED_PARAM, char **argv UNUSED_PARAM) | 146 | int lsmod_main(int argc UNUSED_PARAM, char **argv UNUSED_PARAM) |
147 | { | 147 | { |
148 | FILE *file = xfopen("/proc/modules", "r"); | 148 | FILE *file = xfopen_for_read("/proc/modules"); |
149 | 149 | ||
150 | printf("Module Size Used by"); | 150 | printf("Module Size Used by"); |
151 | check_tainted(); | 151 | check_tainted(); |