]> git.ipfire.org Git - thirdparty/haproxy.git/commit
BUG/MEDIUM: mworker: Set FD_CLOEXEC flag on log fd
authorChristopher Faulet <cfaulet@haproxy.com>
Tue, 19 Dec 2017 09:35:53 +0000 (10:35 +0100)
committerWilly Tarreau <w@1wt.eu>
Tue, 19 Dec 2017 13:03:30 +0000 (14:03 +0100)
commit789691778fde0e792377b631e2c076f449ce6515
treeed0ea1268c310a3dd5c13699eaa605561609479d
parent60a2ee79453681822beb31864b028af66dcf4b0a
BUG/MEDIUM: mworker: Set FD_CLOEXEC flag on log fd

A log socket (UDP or UNIX) is opened by the master during its startup, when the
first log message is sent. So, to prevent FD leaks, we must ensure we correctly
close it during a reload. By setting FD_CLOEXEC bit on it, we are sure it will
be automatically closed it during a reload.

This patch must be backported in 1.8.
src/log.c