[Bug 3853] MIPS mmap can not access over 4G file
bugzilla at busybox.net
bugzilla at busybox.net
Wed Apr 25 11:35:25 UTC 2012
https://bugs.busybox.net/show_bug.cgi?id=3853
--- Comment #11 from Bernhard Reutner-Fischer <aldot at uclibc.org> 2012-04-25 11:35:24 UTC ---
Mike, can you please have a look?
Something like below may be appropriate, but why can't we just use
(off_t)offset>>shift, again?
index 0086496..75b4ebc 100644
--- a/libc/sysdeps/linux/common/mmap64.c
+++ b/libc/sysdeps/linux/common/mmap64.c
@@ -57,7 +57,7 @@ void *mmap64(void *addr, size_t len, int prot, int flags, int
fd, __off64_t offs
* an unsigned 64-bit value before doing the shift.
*/
return (void*) INLINE_SYSCALL(mmap2, 6, addr, len, prot, flags, fd,
- ((uint64_t)offset >> MMAP2_PAGE_SHIFT));
+ (off_t)((uint64_t)offset >>
MMAP2_PAGE_SHIFT));
}
#endif
--
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the uClibc-cvs
mailing list