aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/lib.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/lib.c b/lib/lib.c
index 3deabda2..2c2ea63e 100644
--- a/lib/lib.c
+++ b/lib/lib.c
@@ -672,7 +672,7 @@ void xpidfile(char *name)
spid[xread(fd, spid, sizeof(spid)-1)] = 0;
close(fd);
pid = atoi(spid);
- if (fd < 1 || kill(pid, 0) == ESRCH) unlink(pidfile);
+ if (pid < 1 || kill(pid, 0) == ESRCH) unlink(pidfile);
// An else with more sanity checking might be nice here.
}