Set the CLOEXEC flag on the umbilical socket.
This commit is contained in:
parent
87e0952773
commit
0a786ffbb9
1 changed files with 4 additions and 0 deletions
|
@ -370,6 +370,10 @@ int main(int argc, char **argv) {
|
||||||
umbilical = atoi(umbstr);
|
umbilical = atoi(umbstr);
|
||||||
if(fcntl(umbilical, F_GETFL) < 0)
|
if(fcntl(umbilical, F_GETFL) < 0)
|
||||||
umbilical = 0;
|
umbilical = 0;
|
||||||
|
#ifdef FD_CLOEXEC
|
||||||
|
if(umbilical)
|
||||||
|
fcntl(umbilical, F_SETFD, FD_CLOEXEC);
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue