diff options
author | Mattias Andrée <maandree@member.fsf.org> | 2015-12-31 03:31:06 +0100 |
---|---|---|
committer | Mattias Andrée <maandree@member.fsf.org> | 2015-12-31 03:31:06 +0100 |
commit | 5c6f9566ec7f8f0a0066cf423d63a7bdc0d7e599 (patch) | |
tree | bd3729623e8600d53cc366f41e61b0b21e73a1b2 /src/daemon.c | |
parent | some improvements and fixes (diff) | |
download | sat-5c6f9566ec7f8f0a0066cf423d63a7bdc0d7e599.tar.gz sat-5c6f9566ec7f8f0a0066cf423d63a7bdc0d7e599.tar.bz2 sat-5c6f9566ec7f8f0a0066cf423d63a7bdc0d7e599.tar.xz |
fix bugs and improve debugging
Signed-off-by: Mattias Andrée <maandree@member.fsf.org>
Diffstat (limited to 'src/daemon.c')
-rw-r--r-- | src/daemon.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/daemon.c b/src/daemon.c index 830beca..977e845 100644 --- a/src/daemon.c +++ b/src/daemon.c @@ -218,8 +218,7 @@ reopen(int fd, int oflag) return -1; if (dup2(r, fd) == -1) return saved_errno = errno, close(r), errno = saved_errno, -1; - close(fd); - return 0; + return close(r), 0; } |