Re: drop overzealous ERROR: do not initialise statics to 0 or NULLfrom checkpatch.pl

From: Guennadi Liakhovetski
Date: Wed Aug 13 2008 - 16:19:31 EST


On Wed, 13 Aug 2008, John Kacur wrote:

> Could we drop this somewhat overzealous "ERROR: do not initialise
> statics to 0 or NULL" from checkpatch.pl?
>
> Reasoning:
> 1. This is not part of Documentation/CodingStyle
> 2. K&R 2nd.ed do it (pg 83, static int bufp = 0;) The purpose is to
> remove access to the bufp from external routines, and to avoid name
> conflict)

No, "static" "removes access to the bufp from external routines, and
avoids name conflict", not the initialization to 0.

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/