[PATCH] 2.6 ppc64 Janitor prom.c memleak; whitespace

Paul Mackerras paulus at samba.org
Fri Jul 23 06:24:41 EST 2004


Linas Vepstas writes:

> I had reason to review prom.c today, and saw one minor bug (a very
> unlikely memory leak) and a lot of bad indentation (8 spaces used
> where tab should have been used). Bad whitespace drives me crazy
> because my vi set ts=3 not 8. This patch fixes the mem leak (at very
> bottom of the patch) and lots of whitespace ick. The mem leak is
> unlikely because it requires other failures to happen before the
> memleak happens.

Please don't combine extensive whitespace-only changes with real bug
fixes.  I'll send on the whitespace changes from your patch.

With the memory leak, I agree it needs to be fixed, but it seems to me
that if of_finish_dynamic_node() fails, we will still leak
np->full_name, even with your patch.  Also there are memory leaks in
the failure paths of of_finish_dynamic_node.  (If you feel like fixing
those, fine, but don't feel you have to. :)

Regards,
Paul.

** Sent via the linuxppc64-dev mail list. See http://lists.linuxppc.org/





More information about the Linuxppc64-dev mailing list