summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/util/server.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/util/server.c b/src/util/server.c
index 39cc1277..c59c193b 100644
--- a/src/util/server.c
+++ b/src/util/server.c
@@ -175,7 +175,7 @@ int pidfile(const char *path, const char *name)
errno = 0;
written = sss_atomic_write_s(fd, pid_str, size);
- if (ret == -1) {
+ if (written == -1) {
err = errno;
DEBUG(SSSDBG_CRIT_FAILURE,
("write failed [%d][%s]\n", err, strerror(err)));