Re: [PATCH] cpuset: sparse warnings in cpuset.c

From: Paul Jackson
Date: Sun Feb 03 2008 - 02:28:33 EST


Harvey wrote:
> No need to redeclare p, we have finished with it at this point,
> so reuse it in the for loop.

Good catch, however I disagree with the fix. It makes the code more
brittle.

It's not a good idea to reuse a variable for some other purpose just
because you "know" the original use is dead. Things don't necessarily
stay dead; code moves around.

Could you prepare a revised version of this patch, that instead of
dropping that declaration of 'p', rather renames it to 'q' ?

Thanks.

--
I won't rest till it's the best ...
Programmer, Linux Scalability
Paul Jackson <pj@xxxxxxx> 1.940.382.4214
--
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/