diff options
author | Cyrill Gorcunov <gorcunov@openvz.org> | 2010-04-05 20:56:57 +0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@suse.de> | 2010-05-12 15:02:41 -0700 |
commit | 6f84f123139b79420bb384467da38613504f2675 (patch) | |
tree | cbab6991e5f2433aebe0c9d828ac2d0089b04c1d /drivers | |
parent | 9b6ae1138bd46f841aa0639dc3187e2555f9cde6 (diff) |
Staging: hv: Fix up memory leak on HvCleanup
commit fa8ad0257ea256381126ecf447694622216c600f upstream.
Don't assign NULL too early
Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org>
Cc: Hank Janssen <hjanssen@microsoft.com>
Cc: Haiyang Zhang <haiyangz@microsoft.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/staging/hv/Hv.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/hv/Hv.c b/drivers/staging/hv/Hv.c index c2809f2a2ce..b12237f90db 100644 --- a/drivers/staging/hv/Hv.c +++ b/drivers/staging/hv/Hv.c @@ -306,9 +306,9 @@ void HvCleanup(void) DPRINT_ENTER(VMBUS); if (gHvContext.SignalEventBuffer) { + kfree(gHvContext.SignalEventBuffer); gHvContext.SignalEventBuffer = NULL; gHvContext.SignalEventParam = NULL; - kfree(gHvContext.SignalEventBuffer); } if (gHvContext.GuestId == HV_LINUX_GUEST_ID) { |