Subject: type inconsistencies
To: None <email@example.com>
From: Gordon W. Ross <firstname.lastname@example.org>
Date: 03/09/1995 11:26:56
> From: email@example.com
> Date: Thu, 9 Mar 95 10:45:18 est
> Yes. Check the POSIX 1003.1 spec. for the official prototypes for
> mmap, munmap, mprotect, etc.
> POSIX 1003.1 doesn't define any of these, and if it did, I *strongly*
> suspect it would have used size_t in the first place. Right now,
> we're not even consistent; mmap(2) uses size_t, but the rest of them
> use int.
OK, I found my copy of the spec. and you're right, size_t is OK.
Quoting from: IEEE Std. 1003.1b-1993
Section 12: Memory Management
void *mmap(void *addr, size_t len, int prot, int flags,
int fildes, off_t off);
void *munmap(void *addr, size_t len);
void *mprotect(void *addr, size_t len, int prot);