aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--networking/udhcp/signalpipe.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/networking/udhcp/signalpipe.c b/networking/udhcp/signalpipe.c
index 361596580..d52a931a9 100644
--- a/networking/udhcp/signalpipe.c
+++ b/networking/udhcp/signalpipe.c
@@ -36,7 +36,9 @@ static void signal_handler(int sig)
36 * and installs the signal handler */ 36 * and installs the signal handler */
37void udhcp_sp_setup(void) 37void udhcp_sp_setup(void)
38{ 38{
39 socketpair(AF_UNIX, SOCK_STREAM, 0, signal_pipe); 39// BTW, why socketpair and not just pipe?
40 if (socketpair(AF_UNIX, SOCK_STREAM, 0, signal_pipe))
41 bb_perror_msg_and_die("socketpair");
40 fcntl(signal_pipe[0], F_SETFD, FD_CLOEXEC); 42 fcntl(signal_pipe[0], F_SETFD, FD_CLOEXEC);
41 fcntl(signal_pipe[1], F_SETFD, FD_CLOEXEC); 43 fcntl(signal_pipe[1], F_SETFD, FD_CLOEXEC);
42 signal(SIGUSR1, signal_handler); 44 signal(SIGUSR1, signal_handler);