Rob Shearman : rpcrt4: Fix memory leaks of hdr in error paths in RPCRT4_io_thread.
Alexandre Julliard
julliard at winehq.org
Mon Sep 15 06:54:02 CDT 2008
Module: wine
Branch: master
Commit: ffd37b0eeca1b20138d2f3b24402559a2f9f9919
URL: http://source.winehq.org/git/wine.git/?a=commit;h=ffd37b0eeca1b20138d2f3b24402559a2f9f9919
Author: Rob Shearman <robertshearman at gmail.com>
Date: Fri Sep 12 12:57:56 2008 +0100
rpcrt4: Fix memory leaks of hdr in error paths in RPCRT4_io_thread.
---
dlls/rpcrt4/rpc_server.c | 2 ++
1 files changed, 2 insertions(+), 0 deletions(-)
diff --git a/dlls/rpcrt4/rpc_server.c b/dlls/rpcrt4/rpc_server.c
index 7a3a5f6..d79e436 100644
--- a/dlls/rpcrt4/rpc_server.c
+++ b/dlls/rpcrt4/rpc_server.c
@@ -388,6 +388,7 @@ static DWORD CALLBACK RPCRT4_io_thread(LPVOID the_arg)
packet = HeapAlloc(GetProcessHeap(), 0, sizeof(RpcPacket));
if (!packet) {
I_RpcFree(msg->Buffer);
+ RPCRT4_FreeHeader(hdr);
HeapFree(GetProcessHeap(), 0, msg);
break;
}
@@ -397,6 +398,7 @@ static DWORD CALLBACK RPCRT4_io_thread(LPVOID the_arg)
if (!QueueUserWorkItem(RPCRT4_worker_thread, packet, WT_EXECUTELONGFUNCTION)) {
ERR("couldn't queue work item for worker thread, error was %d\n", GetLastError());
I_RpcFree(msg->Buffer);
+ RPCRT4_FreeHeader(hdr);
HeapFree(GetProcessHeap(), 0, msg);
HeapFree(GetProcessHeap(), 0, packet);
break;
More information about the wine-cvs
mailing list