[PATCH] ctdb: Fix the O3 developer build
Martin Schwenke
martin at meltin.net
Thu Jan 14 10:46:12 UTC 2016
On Thu, 14 Jan 2016 11:21:07 +0100, Volker Lendecke
<Volker.Lendecke at SerNet.DE> wrote:
> Review appreciated!
> diff --git a/ctdb/server/ipalloc.c b/ctdb/server/ipalloc.c
> index 9b5579c..ae9e8de 100644
> --- a/ctdb/server/ipalloc.c
> +++ b/ctdb/server/ipalloc.c
> @@ -31,7 +31,7 @@
> /* The calculation part of the IP allocation algorithm. */
> bool ipalloc(struct ipalloc_state *ipalloc_state)
> {
> - bool ret;
> + bool ret = false;
>
> switch (ipalloc_state->algorithm) {
> case IPALLOC_LCP2:
I'm just trying to understand why this type of fix is needed. How do
I see the relevant errors or warnings? Is there a tool that claims
there is a problem here? If so, is there a real problem or are we just
trying to avoid dodgy warnings? :-)
In this particular case the switch covers all the values of the enum,
so ret is always set, hence my lack of understanding. I always
compile with --picky-developer, so I guess I'm trying to
understand what the O3 developer build is....
No grumpiness or sarcasm... just trying to learn! :-)
Thanks...
peace & happiness,
martin
More information about the samba-technical
mailing list