[asterisk-dev] Re: [asterisk-commits] kpfleming: branch 1.4 r48998
- in /branches/1.4: include/asterisk/ main/
Kevin P. Fleming
kpfleming at digium.com
Wed Dec 27 14:49:31 MST 2006
Luigi Rizzo wrote:
> Uninitialized global or static variables are defined as 0 by the
> relevant C standards, and the 'uninitialized' version is preferred
> because this way the variables don't take space in the image file:
> only the total size is stored, and the loader initializes the memory
> before giving control to the program.
I know this is true for static variables at file-level scope, but I did
not know it was true for non-static variables. However, now that I have
read the specs again, I see that 'static' is used with multiple
meanings... so in this case, it's 'static duration', so it defaults to zero.
Never mind :-)
More information about the asterisk-dev
mailing list