32 lines
996 B
Diff
32 lines
996 B
Diff
From: "K. Y. Srinivasan" <kys@microsoft.com>
|
|
Date: Mon, 12 Dec 2011 09:29:16 -0800
|
|
Subject: [PATCH 30/77] Drivers: hv: Fix a memory leak
|
|
|
|
commit 8b8ee6753154dd6cfe397e0d29fe7f90a8adb50b upstream.
|
|
|
|
There was a memory leak in a failure path in vmbus_process_offer().
|
|
Fix it.
|
|
|
|
Signed-off-by: K. Y. Srinivasan <kys@microsoft.com>
|
|
Signed-off-by: Haiyang Zhang <haiyangz@microsoft.com>
|
|
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
|
|
---
|
|
drivers/hv/channel_mgmt.c | 1 +
|
|
1 file changed, 1 insertion(+)
|
|
|
|
diff --git a/drivers/hv/channel_mgmt.c b/drivers/hv/channel_mgmt.c
|
|
index 12b85ff..b91af50 100644
|
|
--- a/drivers/hv/channel_mgmt.c
|
|
+++ b/drivers/hv/channel_mgmt.c
|
|
@@ -287,6 +287,7 @@ static void vmbus_process_offer(struct work_struct *work)
|
|
spin_lock_irqsave(&vmbus_connection.channel_lock, flags);
|
|
list_del(&newchannel->listentry);
|
|
spin_unlock_irqrestore(&vmbus_connection.channel_lock, flags);
|
|
+ kfree(newchannel->device_obj);
|
|
|
|
free_channel(newchannel);
|
|
} else {
|
|
--
|
|
1.7.9.5
|
|
|