diff options
author | alex <alex@FreeBSD.org> | 1997-12-31 01:22:01 +0000 |
---|---|---|
committer | alex <alex@FreeBSD.org> | 1997-12-31 01:22:01 +0000 |
commit | fb5c76c1763ca3b81193a25fc072df49e47829f3 (patch) | |
tree | f6b982eacadb4b17b938c279c441d37f460d52a5 /lib/libc/sys/mmap.c | |
parent | 43004709f3b48766d3fb67bb59836a5b7af63623 (diff) | |
download | FreeBSD-src-fb5c76c1763ca3b81193a25fc072df49e47829f3.zip FreeBSD-src-fb5c76c1763ca3b81193a25fc072df49e47829f3.tar.gz |
Convert caddr_t --> void * for sys/mman.h functions.
mlock, mmap, mprotect, msync, munlock, and munmap are defined by
POSIX as taking void *. The const modifier has been added to
mlock, munlock, and mprotect as the standard dictates.
minherit comes from OpenBSD and has been updated to conform with
their recent change to void *.
madvise and mincore are not defined by POSIX, but their arguments
have been modified to be consistent with the POSIX-defined functions.
mincore takes a const pointer, but madvise does not due to the
MADV_FREE case.
Discussed with: bde
Diffstat (limited to 'lib/libc/sys/mmap.c')
-rw-r--r-- | lib/libc/sys/mmap.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libc/sys/mmap.c b/lib/libc/sys/mmap.c index 67da734..c011692 100644 --- a/lib/libc/sys/mmap.c +++ b/lib/libc/sys/mmap.c @@ -43,9 +43,9 @@ static char sccsid[] = "@(#)mmap.c 8.1 (Berkeley) 6/17/93"; * This function provides 64-bit offset padding that * is not supplied by GCC 1.X but is supplied by GCC 2.X. */ -caddr_t +void * mmap(addr, len, prot, flags, fd, offset) - caddr_t addr; + void * addr; size_t len; int prot; int flags; @@ -53,6 +53,6 @@ mmap(addr, len, prot, flags, fd, offset) off_t offset; { - return((caddr_t)__syscall((quad_t)SYS_mmap, addr, len, prot, flags, + return((void *)__syscall((quad_t)SYS_mmap, addr, len, prot, flags, fd, 0, offset)); } |