Commit 0f1fb6c0 authored by Derek Buitenhuis's avatar Derek Buitenhuis Committed by Martin Storsjö
Browse files

libavutil: Don't use fcntl if the function does not exist



Not all platforms have the function.
Signed-off-by: default avatarDerek Buitenhuis <derek.buitenhuis@gmail.com>
Signed-off-by: default avatarMartin Storsjö <martin@martin.st>
parent e8edf4e1
......@@ -52,8 +52,11 @@ int avpriv_open(const char *filename, int flags, ...)
#endif
fd = open(filename, flags, mode);
#if HAVE_FCNTL
if (fd != -1)
fcntl(fd, F_SETFD, FD_CLOEXEC);
#endif
return fd;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment