summaryrefslogtreecommitdiff
path: root/absl/base
diff options
context:
space:
mode:
authorGravatar Copybara-Service <copybara-worker@google.com>2023-01-06 18:28:05 -0800
committerGravatar Copybara-Service <copybara-worker@google.com>2023-01-06 18:28:05 -0800
commite160c5f534fead21162c8951d4cfc975d0377896 (patch)
tree4c45d0d867e8a8fd05e59c9f1dd41d9ae3a6523c /absl/base
parent625a18016d6208c6c0419697cb6caa3f23ce31bc (diff)
parent45fdade6c0415ec5af3f9312e6311a4ccc682a7b (diff)
Merge pull request #1349 from kraj:remove-off64_t
PiperOrigin-RevId: 500300819 Change-Id: Iacff97071d158843d687c811b0d78d4ddeba9039
Diffstat (limited to 'absl/base')
-rw-r--r--absl/base/internal/direct_mmap.h5
1 files changed, 2 insertions, 3 deletions
diff --git a/absl/base/internal/direct_mmap.h b/absl/base/internal/direct_mmap.h
index 815b8d23..14efc637 100644
--- a/absl/base/internal/direct_mmap.h
+++ b/absl/base/internal/direct_mmap.h
@@ -72,7 +72,7 @@ namespace base_internal {
// Platform specific logic extracted from
// https://chromium.googlesource.com/linux-syscall-support/+/master/linux_syscall_support.h
inline void* DirectMmap(void* start, size_t length, int prot, int flags, int fd,
- off64_t offset) noexcept {
+ off_t offset) noexcept {
#if defined(__i386__) || defined(__ARM_ARCH_3__) || defined(__ARM_EABI__) || \
defined(__m68k__) || defined(__sh__) || \
(defined(__hppa__) && !defined(__LP64__)) || \
@@ -101,8 +101,7 @@ inline void* DirectMmap(void* start, size_t length, int prot, int flags, int fd,
static_cast<size_t>(offset / pagesize));
#else
return reinterpret_cast<void*>(
- syscall(SYS_mmap2, start, length, prot, flags, fd,
- static_cast<off_t>(offset / pagesize)));
+ syscall(SYS_mmap2, start, length, prot, flags, fd, offset / pagesize));
#endif
#elif defined(__s390x__)
// On s390x, mmap() arguments are passed in memory.