Commit fa8ad025 authored by Cyrill Gorcunov's avatar Cyrill Gorcunov Committed by Greg Kroah-Hartman

Staging: hv: Fix up memory leak on HvCleanup

Don't assign NULL too early
Signed-off-by: default avatarCyrill Gorcunov <gorcunov@openvz.org>
Cc: Hank Janssen <hjanssen@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Cc: stable <stable@kernel.org>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@suse.de>
parent 95beae90
...@@ -306,9 +306,9 @@ void HvCleanup(void) ...@@ -306,9 +306,9 @@ void HvCleanup(void)
DPRINT_ENTER(VMBUS); DPRINT_ENTER(VMBUS);
if (gHvContext.SignalEventBuffer) { if (gHvContext.SignalEventBuffer) {
kfree(gHvContext.SignalEventBuffer);
gHvContext.SignalEventBuffer = NULL; gHvContext.SignalEventBuffer = NULL;
gHvContext.SignalEventParam = NULL; gHvContext.SignalEventParam = NULL;
kfree(gHvContext.SignalEventBuffer);
} }
if (gHvContext.HypercallPage) { if (gHvContext.HypercallPage) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment