diff options
Diffstat (limited to 'src/ppp-watch.c')
-rw-r--r-- | src/ppp-watch.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/ppp-watch.c b/src/ppp-watch.c index c611d7e4..6a304179 100644 --- a/src/ppp-watch.c +++ b/src/ppp-watch.c @@ -162,6 +162,9 @@ detach(char *device) { * of the pppd process to its parent (i.e., it reads nothing). */ close (pipeArray[0]); + /* Don't leak this into programs we call. */ + fcntl(pipeArray[1], F_SETFD, FD_CLOEXEC); + /* Redirect stdio to /dev/null. */ fd = open("/dev/null", O_RDONLY); dup2(fd, STDIN_FILENO); |