summaryrefslogtreecommitdiff
path: root/applets
diff options
context:
space:
mode:
authorErik Andersen2000-03-04 21:19:32 +0000
committerErik Andersen2000-03-04 21:19:32 +0000
commit029011b9eeaf491d00fda1d072c4c6094df96c3a (patch)
tree7c49f1fc1547a2f9cee812472f422a5c1a5c448b /applets
parent7c4b2f3fe5cb6b9a5c6bd089c18279c5ce29dc21 (diff)
downloadbusybox-029011b9eeaf491d00fda1d072c4c6094df96c3a.zip
busybox-029011b9eeaf491d00fda1d072c4c6094df96c3a.tar.gz
A few updates (including the cp fix the Craig has been looking for)
-Erik
Diffstat (limited to 'applets')
-rw-r--r--applets/busybox.c18
1 files changed, 14 insertions, 4 deletions
diff --git a/applets/busybox.c b/applets/busybox.c
index 13f8db9..a80a567 100644
--- a/applets/busybox.c
+++ b/applets/busybox.c
@@ -300,15 +300,17 @@ static const struct Applet applets[] = {
int main(int argc, char **argv)
{
- char *s = argv[0];
- char *name = argv[0];
- const struct Applet *a = applets;
+ char *s = argv[0];
+ char *name = argv[0];
+ const struct Applet *a = applets;
while (*s != '\0') {
if (*s++ == '/')
name = s;
}
+ *argv = name;
+
while (a->name != 0) {
if (strcmp(name, a->name) == 0) {
int status;
@@ -341,7 +343,7 @@ int busybox_main(int argc, char **argv)
fprintf(stderr, "Usage: busybox [function] [arguments]...\n");
fprintf(stderr, " or: [function] [arguments]...\n\n");
fprintf(stderr,
- "\tMost people will create a symlink to busybox for each\n"
+ "\tMost people will create a link to busybox for each\n"
"\tfunction name, and busybox will act like whatever you invoke it as.\n");
fprintf(stderr, "\nCurrently defined functions:\n");
@@ -362,3 +364,11 @@ int busybox_main(int argc, char **argv)
return (main(argc, argv));
}
}
+
+/*
+Local Variables:
+c-file-style: "linux"
+c-basic-offset: 4
+tab-width: 4
+End:
+*/