From 1d786a04635ba643bd09104783f0b8b4671318d2 Mon Sep 17 00:00:00 2001 From: rswindell <> Date: Sat, 31 Aug 2019 02:51:40 +0000 Subject: [PATCH] Don't use Linux OFD locks in builds without Large File Support because: https://patchwork.kernel.org/patch/9289177/ --- src/xpdev/filewrap.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/xpdev/filewrap.c b/src/xpdev/filewrap.c index 2ebbb74c8f..7169e472a7 100644 --- a/src/xpdev/filewrap.c +++ b/src/xpdev/filewrap.c @@ -86,6 +86,11 @@ off_t DLLCALL filelength(int fd) return(st.st_size); } +// See https://patchwork.kernel.org/patch/9289177/ +#if defined(F_OFD_SETLK) && defined(_FILE_OFFSET_BITS) && _FILE_OFFSET_BITS != 64 + #undef F_OFD_SETLK +#endif + /* Sets a lock on a portion of a file */ int DLLCALL lock(int fd, off_t pos, off_t len) { -- GitLab