1From 674d844c52cba11a5a80cb864161b97f1529fe5c Mon Sep 17 00:00:00 2001 2From: Khem Raj <raj.khem@gmail.com> 3Date: Wed, 14 Dec 2022 20:56:44 -0800 4Subject: ext2fs: Use 64bit lseek when _FILE_OFFSET_BITS is 64 5 6Use lseek() with 64bit off_t when _FILE_OFFSET_BITS is 64 7this fixes build with musl where there is no _llseek but lseek 8is using off_t which is 64bit on musl 9 10Signed-off-by: Khem Raj <raj.khem@gmail.com> 11Signed-off-by: Theodore Ts'o <tytso@mit.edu> 12--- 13 lib/ext2fs/llseek.c | 4 ++-- 14 1 file changed, 2 insertions(+), 2 deletions(-) 15 16diff --git a/lib/ext2fs/llseek.c b/lib/ext2fs/llseek.c 17index 922a0d56..45f21d09 100644 18--- a/lib/ext2fs/llseek.c 19+++ b/lib/ext2fs/llseek.c 20@@ -51,7 +51,7 @@ extern long long llseek (int fd, long long offset, int origin); 21 22 #else /* ! HAVE_LLSEEK */ 23 24-#if SIZEOF_LONG == SIZEOF_LONG_LONG 25+#if SIZEOF_LONG == SIZEOF_LONG_LONG || _FILE_OFFSET_BITS+0 == 64 26 27 #define my_llseek lseek 28 29@@ -69,7 +69,7 @@ static int _llseek (unsigned int, unsigned long, 30 31 static _syscall5(int,_llseek,unsigned int,fd,unsigned long,offset_high, 32 unsigned long, offset_low,ext2_loff_t *,result, 33- unsigned int, origin) 34+ unsigned int, origin); 35 #endif 36 37 static ext2_loff_t my_llseek (int fd, ext2_loff_t offset, int origin) 38-- 39cgit 40 41