aboutsummaryrefslogtreecommitdiffstats
path: root/src/unix/Daemon.cxx
diff options
context:
space:
mode:
authorMax Kellermann <max@duempel.org>2015-08-15 16:41:21 +0200
committerMax Kellermann <max@duempel.org>2015-08-15 16:41:21 +0200
commit28a0c46ca7dd06d4e57bec2593a86c32b3b31667 (patch)
tree4d5a9a64977ea542abad45f0689efed1eb7a56e7 /src/unix/Daemon.cxx
parent7cc33d0f27833744729deb585dadde0098afc1cf (diff)
downloadmpd-28a0c46ca7dd06d4e57bec2593a86c32b3b31667.tar.gz
mpd-28a0c46ca7dd06d4e57bec2593a86c32b3b31667.tar.xz
mpd-28a0c46ca7dd06d4e57bec2593a86c32b3b31667.zip
unix/Daemon: eliminate local variable "ret"
Diffstat (limited to 'src/unix/Daemon.cxx')
-rw-r--r--src/unix/Daemon.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/unix/Daemon.cxx b/src/unix/Daemon.cxx
index c3638cc80..4bb11aeac 100644
--- a/src/unix/Daemon.cxx
+++ b/src/unix/Daemon.cxx
@@ -66,7 +66,7 @@ void
daemonize_kill(void)
{
FILE *fp;
- int pid, ret;
+ int pid;
if (pidfile.IsNull())
FatalError("no pid_file specified in the config file");
@@ -85,8 +85,7 @@ daemonize_kill(void)
}
fclose(fp);
- ret = kill(pid, SIGTERM);
- if (ret < 0)
+ if (kill(pid, SIGTERM) < 0)
FormatFatalSystemError("unable to kill process %i",
int(pid));