Messages in this thread | | | From | Oliver Neukum <> | Subject | Re: [PATCH v2] drivers: code cleanups | Date | Wed, 14 Jul 2010 12:02:46 +0200 |
| |
Am Mittwoch, 14. Juli 2010, 11:42:56 schrieb Changli Gao: > drivers: code cleanups > > the first three goto clauses caused kfree(NULL), and the error code returned > by kset->uevent_ops->uevent() wasn't passed to the caller of show_uevent(). > This patch also eliminates the unnecessary initializations of env and count.
This is not a good idea. If you are indeed fixing a bug of not returning an error, make a patch that does that. The other parts of your patch really are no improvement, because they make things harder to maintain if additional cleanups or locking must ever be added.
Regards Oliver
| |