Welcome to mirror list, hosted at ThFree Co, Russian Federation.

cygwin.com/git/newlib-cygwin.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCorinna Vinschen <corinna@vinschen.de>2009-01-17 20:20:37 +0300
committerCorinna Vinschen <corinna@vinschen.de>2009-01-17 20:20:37 +0300
commit895d15b81e7443a15210e61fb6083c21f7b00f4b (patch)
tree7de49cc16394bbdb3aff284024e2284a0d39bb11 /winsup/cygwin/mmap.cc
parent96ed5e24410a1c2d846dda794a64a4a95ddd2275 (diff)
* mmap.cc (mmap64): Fix condition checking if anonymous mapping beyond
EOF is required.
Diffstat (limited to 'winsup/cygwin/mmap.cc')
-rw-r--r--winsup/cygwin/mmap.cc4
1 files changed, 3 insertions, 1 deletions
diff --git a/winsup/cygwin/mmap.cc b/winsup/cygwin/mmap.cc
index 53e552368..30410692f 100644
--- a/winsup/cygwin/mmap.cc
+++ b/winsup/cygwin/mmap.cc
@@ -897,7 +897,9 @@ mmap64 (void *addr, size_t len, int prot, int flags, int fd, _off64_t off)
WOW64 does not support the AT_ROUND_TO_PAGE flag which is required
to get this right. Too bad. */
if (!wincap.is_wow64 ()
- && ((len > fsiz && !autogrow (flags)) || len < pagesize))
+ && ((len > fsiz && !autogrow (flags))
+ || roundup2 (len, getsystempagesize ())
+ < roundup2 (len, pagesize)))
orig_len = len;
if (len > fsiz)
{