diff options
Diffstat (limited to 'lsmod.c')
-rw-r--r-- | lsmod.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -28,13 +28,13 @@ | |||
28 | extern int lsmod_main(int argc, char **argv) | 28 | extern int lsmod_main(int argc, char **argv) |
29 | { | 29 | { |
30 | #if defined BB_FEATURE_USE_DEVPS_PATCH | 30 | #if defined BB_FEATURE_USE_DEVPS_PATCH |
31 | char *cmd[] = { "cat", "/dev/modules", "\0" }; | 31 | char *filename = "/dev/modules"; |
32 | #else | 32 | #else |
33 | #if ! defined BB_FEATURE_USE_PROCFS | 33 | #if ! defined BB_FEATURE_USE_PROCFS |
34 | #error Sorry, I depend on the /proc filesystem right now. | 34 | #error Sorry, I depend on the /proc filesystem right now. |
35 | #endif | 35 | #endif |
36 | char *cmd[] = { "cat", "/proc/modules", "\0" }; | 36 | char *filename = "/proc/modules"; |
37 | #endif | 37 | #endif |
38 | 38 | ||
39 | return(cat_main(3, cmd)); | 39 | return(print_file_by_name(filename)); |
40 | } | 40 | } |