roken: Don't define flock() ops if HAVE_FLOCK (fix #1313)
This commit is contained in:
@@ -890,6 +890,7 @@ ROKEN_LIB_FUNCTION unsigned short ROKEN_LIB_CALL bswap16(unsigned short);
|
||||
* - Fallback to system flock() if available
|
||||
* - Fallback to POSIX fcntl() locks for NFS and other filesystems
|
||||
*/
|
||||
#ifndef HAVE_FLOCK
|
||||
#ifndef LOCK_SH
|
||||
#define LOCK_SH 1 /* Shared lock */
|
||||
#endif
|
||||
@@ -902,6 +903,7 @@ ROKEN_LIB_FUNCTION unsigned short ROKEN_LIB_CALL bswap16(unsigned short);
|
||||
#ifndef LOCK_UN
|
||||
#define LOCK_UN 8 /* Unlock */
|
||||
#endif
|
||||
#endif /* !HAVE_FLOCK */
|
||||
|
||||
ROKEN_LIB_FUNCTION int ROKEN_LIB_CALL rk_flock(int fd, int operation);
|
||||
#define flock(_x,_y) rk_flock(_x,_y)
|
||||
|
||||
Reference in New Issue
Block a user