summaryrefslogtreecommitdiffstats
path: root/lib
diff options
context:
space:
mode:
authorjhb <jhb@FreeBSD.org>2009-07-14 19:45:36 +0000
committerjhb <jhb@FreeBSD.org>2009-07-14 19:45:36 +0000
commitd81f73fcb520cff58dcafda0e644b91837b26a40 (patch)
treec7668a2a58d716a617574fb0350e77267a41f5ee /lib
parent43717b21005a9b854b99f96a6c5ed015e8916d46 (diff)
downloadFreeBSD-src-d81f73fcb520cff58dcafda0e644b91837b26a40.zip
FreeBSD-src-d81f73fcb520cff58dcafda0e644b91837b26a40.tar.gz
- Change mmap() to fail requests with EINVAL that pass a length of 0. This
behavior is mandated by POSIX. - Do not fail requests that pass a length greater than SSIZE_MAX (such as > 2GB on 32-bit platforms). The 'len' parameter is actually an unsigned 'size_t' so negative values don't really make sense. Submitted by: Alexander Best alexbestms at math.uni-muenster.de Reviewed by: alc Approved by: re (kib) MFC after: 1 week
Diffstat (limited to 'lib')
-rw-r--r--lib/libc/sys/mmap.24
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libc/sys/mmap.2 b/lib/libc/sys/mmap.2
index 196d6ae..91bf4e9 100644
--- a/lib/libc/sys/mmap.2
+++ b/lib/libc/sys/mmap.2
@@ -28,7 +28,7 @@
.\" @(#)mmap.2 8.4 (Berkeley) 5/11/95
.\" $FreeBSD$
.\"
-.Dd October 24, 2008
+.Dd July 14, 2009
.Dt MMAP 2
.Os
.Sh NAME
@@ -306,7 +306,7 @@ resides out of the valid address space for a user process.
The
.Fa len
argument
-was negative.
+was equal to zero.
.It Bq Er EINVAL
.Dv MAP_ANON
was specified and the
OpenPOWER on IntegriCloud