summaryrefslogtreecommitdiff
path: root/lib/util
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2012-12-06 16:02:57 +0100
committerGünther Deschner <gd@samba.org>2012-12-12 09:42:33 +0100
commitac434c4223ba7a7cbbd97a59e305445a22a32c76 (patch)
tree9cb493169465ec4c20cfdcb5cd412de5373a787a /lib/util
parentf1fe877d07d6b1d04e9bbbec558bad90a855ae95 (diff)
downloadsamba-ac434c4223ba7a7cbbd97a59e305445a22a32c76.tar.gz
samba-ac434c4223ba7a7cbbd97a59e305445a22a32c76.tar.bz2
samba-ac434c4223ba7a7cbbd97a59e305445a22a32c76.zip
util: Don't use the pid ret value uninitialized.
Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Guenther Deschner <gd@samba.org>
Diffstat (limited to 'lib/util')
-rw-r--r--lib/util/pidfile.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/util/pidfile.c b/lib/util/pidfile.c
index 88463711f9..1b382d1217 100644
--- a/lib/util/pidfile.c
+++ b/lib/util/pidfile.c
@@ -36,7 +36,7 @@ pid_t pidfile_pid(const char *piddir, const char *name)
{
int fd;
char pidstr[20];
- pid_t ret;
+ pid_t ret = -1;
char *pidFile;
if (asprintf(&pidFile, "%s/%s.pid", piddir, name) < 0) {