ALSA: line6: Fix memory leak at probe error path
authorTakashi Iwai <tiwai@suse.de>
Fri, 23 Jan 2015 11:27:39 +0000 (12:27 +0100)
committerTakashi Iwai <tiwai@suse.de>
Wed, 28 Jan 2015 06:20:21 +0000 (07:20 +0100)
commit6b562f63dd603443c97c885daa2b88bff700b2dc
tree9ea79c17cbc302284385739f95ccbe5d23ba0677
parent644d90850c65c6ac5698e4fadb01682196a25eea
ALSA: line6: Fix memory leak at probe error path

Fix memory leak at probe error path by rearranging the call order in
line6_destruct() so that the common destructor is always called.
Also this simplifies the error path to a single goto label.

Tested-by: Chris Rorvick <chris@rorvick.com>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
sound/usb/line6/driver.c