mmap beyond fileend

Lars Hofhansl (lhofhans@indiana.edu)
Sat, 01 Feb 1997 22:23:51 -0600


Hi,

since mmap() allocates space in units of pages,
are the bytes after the end of the file to the end
of the page initialized to 0?
Are the bytes after the last page initialized 0?

I installed the e2compress-patch
(http://netspace.net.au/~reiter/e2compr.html) and noticed,
that the bytes after the fileend just contain garbage.

If this is not the right behavior, is it save to modify
the new readpage() routine (as replacement for
generic_readpage() ) to initialize the whole page
with 0, before actually reading the page, or will this have
any bad sideefects ?

TIA,

Lars