From: Mike Frysinger Date: Tue, 3 Jan 2006 23:59:17 +0000 (-0000) Subject: just use bb_xfopen() X-Git-Tag: 1_1_0~381 X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=705fad296447295ef4e71e301c5b7cdbf186d6a1;p=oweals%2Fbusybox.git just use bb_xfopen() --- diff --git a/modutils/lsmod.c b/modutils/lsmod.c index f2ee19f8f..3d9f700fb 100644 --- a/modutils/lsmod.c +++ b/modutils/lsmod.c @@ -169,10 +169,7 @@ extern int lsmod_main(int argc, char **argv) FILE *file; char line[4096]; - file = fopen("/proc/modules", "r"); - - if (!file) - bb_error_msg_and_die("Opening /proc/modules"); + file = bb_xfopen("/proc/modules", "r"); while (fgets(line, sizeof(line), file)) { char *tok;