diff options
author | Jeffrey Stedfast <fejj@ximian.com> | 2003-12-17 03:38:44 +0000 |
---|---|---|
committer | Jeffrey Stedfast <fejj@src.gnome.org> | 2003-12-17 03:38:44 +0000 |
commit | d6a615c281eb2fd87bf65a01c728b547c414f419 (patch) | |
tree | 915204229576cbc891f8ec7920e28cb21261104b | |
parent | 0f414d72647a7a411ded2b02a2eb307af47bb516 (diff) | |
download | gmime-d6a615c281eb2fd87bf65a01c728b547c414f419.tar.gz |
Don't add getpagesize() to the map length.
2003-12-16 Jeffrey Stedfast <fejj@ximian.com>
* gmime/gmime-stream-mmap.c (g_mime_stream_mmap_new): Don't add
getpagesize() to the map length.
(g_mime_stream_mmap_new_with_bounds): Same.
-rw-r--r-- | ChangeLog | 6 | ||||
-rw-r--r-- | gmime/gmime-stream-mmap.c | 4 |
2 files changed, 8 insertions, 2 deletions
@@ -1,3 +1,9 @@ +2003-12-16 Jeffrey Stedfast <fejj@ximian.com> + + * gmime/gmime-stream-mmap.c (g_mime_stream_mmap_new): Don't add + getpagesize() to the map length. + (g_mime_stream_mmap_new_with_bounds): Same. + 2003-12-06 Jeffrey Stedfast <fejj@ximian.com> * gmime/gmime-parser.c (parser_step_headers): If scanning for eoln diff --git a/gmime/gmime-stream-mmap.c b/gmime/gmime-stream-mmap.c index c5886347..2d2605fd 100644 --- a/gmime/gmime-stream-mmap.c +++ b/gmime/gmime-stream-mmap.c @@ -348,7 +348,7 @@ g_mime_stream_mmap_new (int fd, int prot, int flags) if (fstat (fd, &st) == -1) return NULL; - map = mmap (NULL, st.st_size + getpagesize (), prot, flags, fd, 0); + map = mmap (NULL, st.st_size, prot, flags, fd, 0); if (map == MAP_FAILED) return NULL; @@ -395,7 +395,7 @@ g_mime_stream_mmap_new_with_bounds (int fd, int prot, int flags, off_t start, of } else st.st_size = end /* - start */; - map = mmap (NULL, st.st_size + getpagesize (), prot, flags, fd, 0); + map = mmap (NULL, st.st_size, prot, flags, fd, 0); if (map == MAP_FAILED) return NULL; |