maximilian attems
2011-Sep-06 13:48 UTC
[klibc] [PATCH] include: [sys/file.h] define flock(2) there
SUSv3 is silent on that definition, but seen several userspace software that expects flock to be defined in that file and complain that it is missing in klibc. Current declaration is in unistd.h. Signed-off-by: maximilian attems <max at stro.at> --- usr/include/sys/file.h | 9 +++++++++ usr/include/unistd.h | 1 - 2 files changed, 9 insertions(+), 1 deletions(-) create mode 100644 usr/include/sys/file.h diff --git a/usr/include/sys/file.h b/usr/include/sys/file.h new file mode 100644 index 0000000..7b580f3 --- /dev/null +++ b/usr/include/sys/file.h @@ -0,0 +1,9 @@ +#ifndef _SYS_FILE_H +#define _SYS_FILE_H + +/* LOCK_ definitions */ +#include <fcntl.h> + +__extern int flock(int, int); + +#endif /* _SYS_FILE_H */ diff --git a/usr/include/unistd.h b/usr/include/unistd.h index f286c33..3eaeaee 100644 --- a/usr/include/unistd.h +++ b/usr/include/unistd.h @@ -105,7 +105,6 @@ __extern int dup(int); __extern int dup2(int, int); __extern int fcntl(int, int, ...); __extern int ioctl(int, int, void *); -__extern int flock(int, int); __extern int ftruncate(int, off_t); /* -- 1.7.5.4
Reasonably Related Threads
- [GIT PULL] klibc minor fixes
- Windows share modes and Linux file locking, flock & fcntl
- [PATCH] include: [sys/socket.h] Fix bind and connect attributes
- [klibc:master] include: [sys/time.h] fix for Linux 3.5.1
- [PATCH] include: [sys/ioctl.h] needs linux/sockios.h