Set the CLOEXEC flag on the umbilical socket.

This commit is contained in:
Guus Sliepen 2015-05-21 11:06:38 +02:00
parent 87e0952773
commit 0a786ffbb9

View file

@ -370,6 +370,10 @@ int main(int argc, char **argv) {
umbilical = atoi(umbstr);
if(fcntl(umbilical, F_GETFL) < 0)
umbilical = 0;
#ifdef FD_CLOEXEC
if(umbilical)
fcntl(umbilical, F_SETFD, FD_CLOEXEC);
#endif
}
#endif