leds: leds-pca9532 - fix memory leak and properly handle errors
authorSven Wegener <sven.wegener@stealer.net>
Wed, 3 Dec 2008 08:12:53 +0000 (08:12 +0000)
committerRichard Purdie <rpurdie@linux.intel.com>
Thu, 8 Jan 2009 12:38:58 +0000 (12:38 +0000)
When the registration fails, we need to release the memory we allocated.
Also we need to save the error from led_classdev_register and propagate
it up, else we'll return success, even if we failed.

Signed-off-by: Riku Voipio <riku.voipio@iki.fi>
Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>

No differences found