From 4c1b8fc2e514344a55789d6ac9909ce904137578 Mon Sep 17 00:00:00 2001 From: Justin Pettit Date: Mon, 21 Feb 2011 16:27:22 -0800 Subject: [PATCH] daemon: Fix leak of string in make_pidfile(). Coverity #10724 --- lib/daemon.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/daemon.c b/lib/daemon.c index a8b3fae3..2f6f0819 100644 --- a/lib/daemon.c +++ b/lib/daemon.c @@ -223,11 +223,11 @@ make_pidfile(void) pidfile, strerror(errno)); } } - free(text); } else { VLOG_ERR("%s: write failed: %s", tmpfile, strerror(errno)); close(fd); } + free(text); } else { VLOG_ERR("%s: fcntl failed: %s", tmpfile, strerror(errno)); close(fd); -- 2.30.2