summaryrefslogtreecommitdiff
path: root/runit
diff options
context:
space:
mode:
authorDenis Vlasenko2006-10-06 08:54:49 +0000
committerDenis Vlasenko2006-10-06 08:54:49 +0000
commit4e6ceb44554d265eed24c414b9a201d51d00fee2 (patch)
treee8469d6e0b4acd0163ef6ff3dbbe54513b1cc523 /runit
parent000b9ba91f64a348d697fb22a546cfb4db1d9f0e (diff)
downloadbusybox-4e6ceb44554d265eed24c414b9a201d51d00fee2.zip
busybox-4e6ceb44554d265eed24c414b9a201d51d00fee2.tar.gz
chpst: fix vda's silly mistakes
Patch by Vladimir Dronnikov <dronnikov@gmail.ru>
Diffstat (limited to 'runit')
-rw-r--r--runit/chpst.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/runit/chpst.c b/runit/chpst.c
index da2f270..b26d628 100644
--- a/runit/chpst.c
+++ b/runit/chpst.c
@@ -91,7 +91,7 @@ static void edir(const char *directory_name)
bb_perror_msg_and_die("read %s/%s", directory_name, /* was exiting 111 */
d->d_name);
if (size == 0) {
- xsetenv(d->d_name, "");
+ unsetenv(d->d_name);
continue;
}
buf[size] = '\n';
@@ -247,6 +247,7 @@ int chpst_main(int argc, char **argv)
//if (option_mask & 0x10000) OPT_nostdout = 1; // -1
//if (option_mask & 0x20000) OPT_nostderr = 1; // -2
}
+ argv += optind;
if (!argv || !*argv) bb_show_usage();
if (OPT_pgrp) setsid();