diff options
| author | Roy Marples <roy@marples.name> | 2009-01-29 13:01:29 +0000 |
|---|---|---|
| committer | Roy Marples <roy@marples.name> | 2009-01-29 13:01:29 +0000 |
| commit | f22fb9b1c1232dd0385a00d7eb8ad0dbc172dc07 (patch) | |
| tree | f886e73a43b66ad78b3e4be0d6e15d322a586427 /bind.c | |
| parent | ed913a59775402a9ce66067858d7280fe4506176 (diff) | |
| download | dhcpcd-f22fb9b1c1232dd0385a00d7eb8ad0dbc172dc07.tar.xz | |
Clean up compiler warnings from overly pedantic checking.
Diffstat (limited to 'bind.c')
| -rw-r--r-- | bind.c | 6 |
1 files changed, 4 insertions, 2 deletions
@@ -79,7 +79,8 @@ daemonise(void) setsid(); /* Notify parent it's safe to exit as we've detached. */ close(sidpipe[0]); - write(sidpipe[1], &buf, 1); + if (write(sidpipe[1], &buf, 1) == -1) + syslog(LOG_ERR, "failed to notify parent: %m"); close(sidpipe[1]); if ((fd = open(_PATH_DEVNULL, O_RDWR, 0)) != -1) { dup2(fd, STDIN_FILENO); @@ -93,7 +94,8 @@ daemonise(void) signal_reset(); /* Wait for child to detach */ close(sidpipe[1]); - read(sidpipe[0], &buf, 1); + if (read(sidpipe[0], &buf, 1) == -1) + syslog(LOG_ERR, "failed to read child: %m"); close(sidpipe[0]); break; } |
