tools/flock: fix compile on Alpine Linux
authorJohn Crispin <john@openwrt.org>
Thu, 10 Mar 2016 19:10:48 +0000 (19:10 +0000)
committerJohn Crispin <john@openwrt.org>
Thu, 10 Mar 2016 19:10:48 +0000 (19:10 +0000)
fixes build errors:
src/flock.c:208:34: error: 'O_NOCTTY' undeclared (first use in this function)
     fd = open(filename, O_RDONLY|O_NOCTTY|O_CREAT, 0666);
src/flock.c:208:43: error: 'O_CREAT' undeclared (first use in this function)
     fd = open(filename, O_RDONLY|O_NOCTTY|O_CREAT, 0666);

Signed-off-by: Dirk Neukirchen <dirkneukirchen@web.de>
SVN-Revision: 48978

tools/flock/src/flock.c

index 13baec46ca4d5fdbfd496df6c90b0d0870d31c9b..3ac3a4bebce85225d4188149970ef94a74be6549 100644 (file)
@@ -39,6 +39,7 @@
 #include <sys/file.h>
 #include <sys/time.h>
 #include <sys/wait.h>
+#include <fcntl.h>
 
 #define PACKAGE_STRING "util-linux-ng 2.18"
 #define _(x) (x)