aboutsummaryrefslogtreecommitdiff
path: root/lib/cpu-notifier-error-inject.c
diff options
context:
space:
mode:
authorXenia Ragiadakou <[email protected]>2013-08-29 21:45:48 +0300
committerGreg Kroah-Hartman <[email protected]>2013-08-30 12:02:08 -0700
commite3376d6c87eea09bd65ece6073f6e5d47aa560a3 (patch)
tree0d44a8f7a1f48d61534fec9cdaa0d4b3bbe29cd0 /lib/cpu-notifier-error-inject.c
parenteb5ea7300d48c52b028966a6e59f9244faa930d0 (diff)
usbcore: compare and release one bos descriptor in usb_reset_and_verify_device()
In usb_reset_and_verify_device(), hub_port_init() allocates a new bos descriptor to hold the value read by the device. The new bos descriptor has to be compared with the old one in order to figure out if device 's firmware has changed in which case the device has to be reenumerated. In the original code, none of the two descriptors was deallocated leading to memory leaks. This patch compares the old bos descriptor with the new one to detect change in firmware and releases the newly allocated bos descriptor to prevent memory leak. Signed-off-by: Xenia Ragiadakou <[email protected]> Reported-by: Martin MOKREJS <[email protected]> Tested-by: Martin MOKREJS <[email protected]> Suggested-by: Alan Stern <[email protected]> Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'lib/cpu-notifier-error-inject.c')
0 files changed, 0 insertions, 0 deletions