[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [patch] canonicalize_file_name
From: |
Matt Wilson |
Subject: |
Re: [patch] canonicalize_file_name |
Date: |
Wed, 15 Aug 2001 11:08:05 -0400 |
User-agent: |
Mutt/1.2.5i |
On Wed, Aug 15, 2001 at 09:58:34PM +1000, Andrew Clausen wrote:
>
> > -static PedDevice* devices = NULL;
> > +static PedDevice* devices;
>
> I'm not applying that, until I get a legal guarantee (*grin*) that
> this is safe. Why don't the gcc ppl just put this in zero memory,
> if they know it's zero? This is a gcc bug, as far as I'm concerned.
ISO/EIC 9899:1999, section 6.7.8 "Initialization" part 10:
10) If an object that has automatic storage duration is not
initialized explicitly, its value is indeterminate. If an object
that has static storage duration is not initialized explicitly,
then:
- if it has pointer type, it is initialized to a null pointer;
- if it has an arithmetic type, it is initialized to (positive
or unsigned) zero;
- if it is an aggregate, every member is initialized
(recursively) according to these rules;
- if it is a union, the first named member is initialized
(recursively) according to these rules.
So, it should be NULL already.