aboutsummaryrefslogtreecommitdiffstats
path: root/drivers
diff options
context:
space:
mode:
authorJiri Kosina <jkosina@suse.cz>2007-01-24 17:05:07 -0500
committerJiri Kosina <jkosina@suse.cz>2007-01-25 12:31:21 -0500
commit767fe7877c2928b5633992ee60a49ad4516dc2af (patch)
tree9623c4149575ce26af4ff4cf908bec6eb37d4072 /drivers
parent99abfeafb5f2eea1bb481330ff37343e1133c924 (diff)
HID: fix memleaking of collection
hid_free_device() doesn't free device->collection (but it does free device->rdesc and device itself). This imposes memory leak. Fix it. Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Diffstat (limited to 'drivers')
-rw-r--r--drivers/hid/hid-core.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c
index b8cf50fcd64d..49f18f5b2514 100644
--- a/drivers/hid/hid-core.c
+++ b/drivers/hid/hid-core.c
@@ -543,6 +543,7 @@ void hid_free_device(struct hid_device *device)
543 } 543 }
544 544
545 kfree(device->rdesc); 545 kfree(device->rdesc);
546 kfree(device->collection);
546 kfree(device); 547 kfree(device);
547} 548}
548EXPORT_SYMBOL_GPL(hid_free_device); 549EXPORT_SYMBOL_GPL(hid_free_device);