Mail Archives: cygwin/2001/03/19/08:41:39
Hi!
This e-mail concerns the current "mmap" implementation.
When I map the same piece of a file twice into the virtual address space (using
*mmap*)
the second call returns the same address as the first call has returned.
There are some cases, which make a multiple mapping of the same piece of a file
reasonable.
For example setting different protection attributes for two regions of one file:
....
ptr1 = mmap(fd,...,offset);
ptr2 = mmap(fd,...,offset);
....
mprotect(ptr1,PROT_READ,PAGE_SIZE);
mprotect(ptr2,PROT_WRITE|PROT_READ,PAGE_SIZE);
.....
Anyway, I don't think, that the semantic of mmap should be like it is right now
in your implementaion.
Regards Claus Wagner.
ps: ... or should I read the POSIX standard :-)
--
Want to unsubscribe from this list?
Check out: http://cygwin.com/ml/#unsubscribe-simple
- Raw text -