diff options
author | Bernhard Reutner-Fischer | 2006-04-12 18:09:26 +0000 |
---|---|---|
committer | Bernhard Reutner-Fischer | 2006-04-12 18:09:26 +0000 |
commit | 2c99851181a652358aa3ca58ef38c57e46ae02e4 (patch) | |
tree | 6893f7992748817b64ec66947adc2ca40e13fb8e /debianutils/start_stop_daemon.c | |
parent | dac7ff15b7d32deeeef3d9665744fc5774c21d70 (diff) | |
download | busybox-2c99851181a652358aa3ca58ef38c57e46ae02e4.zip busybox-2c99851181a652358aa3ca58ef38c57e46ae02e4.tar.gz |
- patch from Denis Vlasenko to add and use bb_xdaemon()
Diffstat (limited to 'debianutils/start_stop_daemon.c')
-rw-r--r-- | debianutils/start_stop_daemon.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/debianutils/start_stop_daemon.c b/debianutils/start_stop_daemon.c index 5b68974..b44a23b 100644 --- a/debianutils/start_stop_daemon.c +++ b/debianutils/start_stop_daemon.c @@ -275,8 +275,7 @@ start_stop_daemon_main(int argc, char **argv) } *--argv = startas; if (opt & SSD_OPT_BACKGROUND) { - if (daemon(0, 0) == -1) - bb_perror_msg_and_die ("unable to fork"); + bb_xdaemon(0, 0); setsid(); } if (opt & SSD_OPT_MAKEPID) { |