projects
/
platform
/
upstream
/
libusb.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
068ff5b
)
Fix memory leak in config descriptor parsing
author
Daniel Drake
<dsd@gentoo.org>
Tue, 26 May 2009 19:53:26 +0000
(15:53 -0400)
committer
Daniel Drake
<dsd@gentoo.org>
Tue, 26 May 2009 19:53:26 +0000
(15:53 -0400)
Pointed out by Martin Koegler.
libusb/descriptor.c
patch
|
blob
|
history
diff --git
a/libusb/descriptor.c
b/libusb/descriptor.c
index
baff1b0
..
adc6220
100644
(file)
--- a/
libusb/descriptor.c
+++ b/
libusb/descriptor.c
@@
-503,6
+503,7
@@
API_EXPORTED int libusb_get_active_config_descriptor(libusb_device *dev,
usbi_warn(dev->ctx, "descriptor data still left");
}
+ free(buf);
*config = _config;
return 0;
@@
-571,6
+572,7
@@
API_EXPORTED int libusb_get_config_descriptor(libusb_device *dev,
usbi_warn(dev->ctx, "descriptor data still left");
}
+ free(buf);
*config = _config;
return 0;