]> git.baikalelectronics.ru Git - kernel.git/commit
USB: WUSBCORE: fix resource cleanup in error path in __wa_xfer_setup_segs
authorThomas Pugliese <thomas.pugliese@gmail.com>
Thu, 15 Aug 2013 19:37:41 +0000 (14:37 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 16 Aug 2013 00:36:27 +0000 (17:36 -0700)
commitcf082e62177b77f5b857989add9e3e02801b3836
tree1125edc4b5686b73d74d276e2973d85c71b996b0
parente9344e71bc45e0899f2e59492d98d90f6327e3f5
USB: WUSBCORE: fix resource cleanup in error path in __wa_xfer_setup_segs

Use usb_free_urb instead of kfree in error path and point to the correct
URB.  Also remember to clean up the sg list for the URB if it was allocated.

Signed-off-by: Thomas Pugliese <thomas.pugliese@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/usb/wusbcore/wa-xfer.c