policycoreutils/SOURCES/restorecond-fedora.patch

13 lines
400 B
Diff

diff --git restorecond-2.8/restorecond.c restorecond-2.8/restorecond.c
index 6fbbd35..e1d26cb 100644
--- restorecond-2.8/restorecond.c
+++ restorecond-2.8/restorecond.c
@@ -105,6 +105,7 @@ static int write_pid_file(void)
}
if (write(pidfd, val, (unsigned int)len) != len) {
syslog(LOG_ERR, "Unable to write to pidfile (%s)", strerror(errno));
+ close(pidfd);
return 1;
}
close(pidfd);