diff --git a/libc/src/__support/File/linux_file.cpp b/libc/src/__support/File/linux_file.cpp --- a/libc/src/__support/File/linux_file.cpp +++ b/libc/src/__support/File/linux_file.cpp @@ -77,7 +77,7 @@ long ret = __llvm_libc::syscall(SYS_lseek, lf->get_fd(), offset, whence); #elif defined(SYS__llseek) long result; - long ret = __llvm_libc::syscall(SYS__lseek, lf->get_fd(), offset >> 32, + long ret = __llvm_libc::syscall(SYS__llseek, lf->get_fd(), offset >> 32, offset, &result, whence); #else #error "lseek and _llseek syscalls not available to perform a seek operation." diff --git a/libc/src/unistd/linux/lseek.cpp b/libc/src/unistd/linux/lseek.cpp --- a/libc/src/unistd/linux/lseek.cpp +++ b/libc/src/unistd/linux/lseek.cpp @@ -23,8 +23,8 @@ long ret = __llvm_libc::syscall(SYS_lseek, fd, offset, whence); result = ret; #elif defined(SYS__llseek) - long ret = __llvm_libc::syscall(SYS__lseek, fd, offset >> 32, offset, &result, - whence); + long ret = __llvm_libc::syscall(SYS__llseek, fd, offset >> 32, offset, + &result, whence); #else #error "lseek and _llseek syscalls not available." #endif