[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Re: NULL pointers.

From: Daniel Berlin <dberlin_at_dberlin.org>
Date: 2003-10-14 04:21:52 CEST

On Oct 13, 2003, at 9:54 PM, Marc Singer wrote:

> On Mon, Oct 13, 2003 at 06:11:08PM -0700, Jack Repenning wrote:
>>> Sooooo, a simple way of being sure that your memory is initialized
>>> properly, even on systems where a null pointer constant is not
>>> all-zero-bits, is this:
>>>
>>> struct some_complex_struct *foo
>>>
>>> {
>>> struct some_complex_struct __tmp = { 0 };
>>
>> Doesn't this fail for the case where the _first_ field of
>> some_complex_struct is a pointer, and the local architecture does
>> something inane with NULL?
>
> Is there an architecture that doesn't use ((void*) 0) for NULL?

That would violate the C99 standard.

see 6.3.2.3
>

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Tue Oct 14 04:22:41 2003

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.