Re: [PATCH 1/2] fast-import: initialize variable require_explicit_termination
- From
Matthieu Moy <matthieu.moy@grenoble-inp.fr>
- Date
- Aug 26, 2011, 17:59 UTC
- Message-ID
- <vpqr548hx40.fsf@bauges.imag.fr>
- In-Reply-To
- <7v8vqgdpsv.fsf@alter.siamese.dyndns.org>
Junio C Hamano <gitster@pobox.com> writes:
Show 6 quoted lines
> Matthieu Moy <Matthieu.Moy@imag.fr> writes: > >> The uninitialized variable seems harmless in practice, but let's still be clean. > > It is not "in practice", but by definition, file scope "static int" > variables are initialized to 0 by the C language
OK, I didn't know this was specified in C, but you're right.
> Please do not write unnecessary " = 0" there.
I prefer being explicit, but that's a matter of taste, and I don't really care, so let's drop this patch.
-- Matthieu Moy http://www-verimag.imag.fr/~moy/