[OpenAFS-port-darwin] Compiler running off the end of file
Ragnar Sundblad
ragge@nada.kth.se
Wed, 11 Dec 2002 19:35:59 +0100
(Did this get answered?)
--On den 6 december 2002 15:16 +0100 RD Schaffer <R.D.Schaffer@cern.ch>
wrote:
> Hi there,
>
> I am using a powerbook G4 running 10.2.2 having loaded the afs 10.2
> version. This has been working fine for editing/copying/moving files. I
> have now tried to build some of our software which is commonly kept in
> afs and normally build on linux. I am using the 10.2 mac developer's kit
> with gcc 3.2. What I see is that some, but not all C++ files "run off the
> end" of the file with errors:
...
It is probably the same problem that Arla had some year or two ago:
gcc mmaps the file and assumes it ends with a zero byte, the
file system has to zero out the rest of the block for gcc to work.
I'd say it is a bug in gcc, but it is also a security hole that
you get to see data from someone elses file or from some random
memory page.
I have no idea if and/or when this is fixed in the OpenAFS client.
/ragge