[darcs-users] darcs patch: Handle empty files in mmapFilePS. Also cater for FD sh...
kowey at darcs.net
Wed Feb 4 21:15:25 UTC 2009
On Wed, Feb 04, 2009 at 21:58:37 +0100, Petr Rockai wrote:
> Here. To mmap a region of a file, you need to first open that file in an
> appropriate way. That is, the mmap system call takes a filedescriptor, not a
> path. You can't close the file as long as the mapping is active -- which it is
> as long, as the returned bytestring value is active -- its finalizer will call
> munmap (which is triggered by the GC figuring that the object is no longer
Oh! well, I think I understand that explanation. Perhaps Don would
appreciate some sort of haddock patch laying this all out (or maybe
the kind of people who would try to use mmap understand this all
quite clearly already). Barring that maybe a word or two belongs in
Anyway, applied, thanks!
Eric Kow <http://www.nltg.brighton.ac.uk/home/Eric.Kow>
PGP Key ID: 08AC04F9
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Size: 194 bytes
Desc: not available
More information about the darcs-users