Re: comparing file contents in is_exact_match?
- From
Johannes Schindelin <johannes.schindelin@gmx.de>
- Date
- Jul 17, 2006, 16:05 UTC
- Message-ID
- <Pine.LNX.4.63.0607171804030.29667@wbgn013.biozentrum.uni-wuerzburg.de>
- In-Reply-To
- <Pine.LNX.4.64.0607170840280.15611@evo.osdl.org>
Hi,
On Mon, 17 Jul 2006, Linus Torvalds wrote:
Show 7 quoted lines
> On Mon, 17 Jul 2006, Johannes Schindelin wrote: > > > > But note that we usually use the whole contents of the mmap()ed file > > anyway. > > Not for pack-files, though. You may have a half-gigabyte pack-file, and > only use a small small fraction of it.
Right.
> (You also never really rename them, so windows should be fine for that > case)
So we could introduce a second mmap() which is normally the same as mmap(), except for windows, where it is a rename() and unlink() safe version of mmap() by reading the thing into RAM. Not very pretty.
Ciao, Dscho