delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2001/03/19/08:41:39

Mailing-List: contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT sources DOT redhat DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT sources DOT redhat DOT com>
List-Help: <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT sources DOT redhat DOT com
Delivered-To: mailing list cygwin AT sources DOT redhat DOT com
Message-ID: <3AB60CEC.7FB88267@cs.technion.ac.il>
Date: Mon, 19 Mar 2001 15:43:08 +0200
From: Claus Wagner <cwagner AT cs DOT Technion DOT AC DOT IL>
X-Mailer: Mozilla 4.61 [en] (X11; I; Linux 2.2.12-20 i686)
X-Accept-Language: Hebrew, en
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: ?mmap?

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 -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019