summaryrefslogtreecommitdiff
path: root/networking/nc.c
diff options
context:
space:
mode:
Diffstat (limited to 'networking/nc.c')
-rw-r--r--networking/nc.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/networking/nc.c b/networking/nc.c
index 5fd8bd7..0dacaf1 100644
--- a/networking/nc.c
+++ b/networking/nc.c
@@ -216,10 +216,8 @@ int nc_main(int argc, char **argv)
if (execparam) {
pid_t pid;
/* With more than one -l, repeatedly act as server */
- if (do_listen > 1 && (pid = vfork()) != 0) {
- /* parent or error */
- if (pid < 0)
- bb_perror_msg_and_die("vfork");
+ if (do_listen > 1 && (pid = xvfork()) != 0) {
+ /* parent */
/* prevent zombies */
signal(SIGCHLD, SIG_IGN);
close(cfd);