Fix fdopen setting FD_CLOEXEC wrongly.

This commit is contained in:
Jonas 'Sortie' Termansen 2014-08-26 23:13:18 +02:00
parent 783c1092ff
commit 228bf52b49
1 changed files with 1 additions and 1 deletions

View File

@ -136,7 +136,7 @@ extern "C" DIR* fdopendir(int fd)
int old_dflags = fcntl(fd, F_GETFD);
if ( 0 <= old_dflags )
fcntl(fd, F_SETFD, old_dflags | O_CLOEXEC);
fcntl(fd, F_SETFD, old_dflags | FD_CLOEXEC);
info->fd = fd;