]> git.ipfire.org Git - thirdparty/libarchive.git/commitdiff
Define O_CLOEXEC when missing in archive_random.c
authorBrad King <brad.king@kitware.com>
Wed, 21 Oct 2015 18:16:21 +0000 (14:16 -0400)
committerBrad King <brad.king@kitware.com>
Mon, 26 Oct 2015 14:20:50 +0000 (10:20 -0400)
We do this several other sources already.

libarchive/archive_random.c

index b162ff3ae073da6e7056e7f721765a17d8d63797..f4d42547f69e0eb240e4ad5800f251f2f16e4530 100644 (file)
@@ -62,6 +62,10 @@ static void arc4random_buf(void *, size_t);
 #include <wincrypt.h>
 #endif
 
+#ifndef O_CLOEXEC
+#define O_CLOEXEC      0
+#endif
+
 /*
  * Random number generator function.
  * This simply calls arc4random_buf function if the platform provides it.