OSDN Git Service

Bluetooth: hidp: Fix memory leak of cached report descriptor
authorPeter Hurley <peter@hurleysoftware.com>
Fri, 5 Aug 2011 14:51:34 +0000 (10:51 -0400)
committerJaikumar Ganesh <jaikumar@google.com>
Fri, 12 Aug 2011 01:42:08 +0000 (18:42 -0700)
Free the cached HID report descriptor on thread terminate.

Signed-off-by: Peter Hurley <peter@hurleysoftware.com>
Signed-off-by: Gustavo F. Padovan <padovan@profusion.mobi>
net/bluetooth/hidp/core.c

index 7e19a01..26f0d10 100644 (file)
@@ -764,6 +764,7 @@ static int hidp_session(void *arg)
 
        up_write(&hidp_session_sem);
 
+       kfree(session->rd_data);
        kfree(session);
        return 0;
 }