On Sat, Apr 12, 2003 at 12:48:40PM -0500, Nathan Neulinger wrote:
> Basically, if a regular function variable, you have to initialize it if
> you want it's value to be anything other than garbage. Globals are
> initialized to null/zero.

As a clarification, the problem on Darwin (which is what I started
with originally) isn't actually about variable initialziation, but
about whether the global symbol gets exported.  I believe that (when
it is present), the global is properly initialized as zero.

OpenAFS will link and run correctly on Darwin with this:

    struct rxkad_stats rxkad_stats = {}

but not this:

    struct rxkad_stats rxkad_stats;

I really don't know why.

-- 
Alexei Kosut <[EMAIL PROTECTED]> <http://cs.stanford.edu/~akosut/>
_______________________________________________
OpenAFS-devel mailing list
[EMAIL PROTECTED]
https://lists.openafs.org/mailman/listinfo/openafs-devel

Reply via email to