aboutsummaryrefslogtreecommitdiff
path: root/miscutils/makedevs.c
diff options
context:
space:
mode:
authorManuel Novoa III <mjn3@codepoet.org>2003-03-19 09:13:01 +0000
committerManuel Novoa III <mjn3@codepoet.org>2003-03-19 09:13:01 +0000
commitcad5364599eb5062d59e0c397ed638ddd61a8d5d (patch)
treea318d0f03aa076c74b576ea45dc543a5669e8e91 /miscutils/makedevs.c
parente01f9662a5bd5d91be4f6b3941b57fff73cd5af1 (diff)
downloadbusybox-w32-cad5364599eb5062d59e0c397ed638ddd61a8d5d.tar.gz
busybox-w32-cad5364599eb5062d59e0c397ed638ddd61a8d5d.tar.bz2
busybox-w32-cad5364599eb5062d59e0c397ed638ddd61a8d5d.zip
Major coreutils update.
Diffstat (limited to 'miscutils/makedevs.c')
-rw-r--r--miscutils/makedevs.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/miscutils/makedevs.c b/miscutils/makedevs.c
index 67b28b534..308d651ae 100644
--- a/miscutils/makedevs.c
+++ b/miscutils/makedevs.c
@@ -22,7 +22,7 @@ int makedevs_main(int argc, char **argv)
22 int major, Sminor, S, E; 22 int major, Sminor, S, E;
23 23
24 if (argc < 7 || *argv[1]=='-') 24 if (argc < 7 || *argv[1]=='-')
25 show_usage(); 25 bb_show_usage();
26 26
27 basedev = argv[1]; 27 basedev = argv[1];
28 type = argv[2]; 28 type = argv[2];
@@ -45,7 +45,7 @@ int makedevs_main(int argc, char **argv)
45 mode |= S_IFIFO; 45 mode |= S_IFIFO;
46 break; 46 break;
47 default: 47 default:
48 show_usage(); 48 bb_show_usage();
49 } 49 }
50 50
51 while (S <= E) { 51 while (S <= E) {
@@ -53,12 +53,12 @@ int makedevs_main(int argc, char **argv)
53 53
54 sz = snprintf(buf, sizeof(buf), "%s%d", basedev, S); 54 sz = snprintf(buf, sizeof(buf), "%s%d", basedev, S);
55 if(sz<0 || sz>=sizeof(buf)) /* libc different */ 55 if(sz<0 || sz>=sizeof(buf)) /* libc different */
56 error_msg_and_die("%s too large", basedev); 56 bb_error_msg_and_die("%s too large", basedev);
57 57
58 /* if mode != S_IFCHR and != S_IFBLK third param in mknod() ignored */ 58 /* if mode != S_IFCHR and != S_IFBLK third param in mknod() ignored */
59 59
60 if (mknod(nodname, mode, major | Sminor)) 60 if (mknod(nodname, mode, major | Sminor))
61 error_msg("Failed to create: %s", nodname); 61 bb_error_msg("Failed to create: %s", nodname);
62 62
63 if (nodname == basedev) /* ex. /dev/hda - to /dev/hda1 ... */ 63 if (nodname == basedev) /* ex. /dev/hda - to /dev/hda1 ... */
64 nodname = buf; 64 nodname = buf;