Nikolay Sivov : rpcss: Fix potential leaks when removing endpoint ( Coverity).
Alexandre Julliard
julliard at wine.codeweavers.com
Mon May 23 10:27:45 CDT 2016
Module: wine
Branch: master
Commit: a87c510e9a7ff3fd748920525425b7e317a0bbdf
URL: http://source.winehq.org/git/wine.git/?a=commit;h=a87c510e9a7ff3fd748920525425b7e317a0bbdf
Author: Nikolay Sivov <nsivov at codeweavers.com>
Date: Sun May 22 21:44:47 2016 +0300
rpcss: Fix potential leaks when removing endpoint (Coverity).
Signed-off-by: Nikolay Sivov <nsivov at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
programs/rpcss/epmp.c | 8 +++++---
1 file changed, 5 insertions(+), 3 deletions(-)
diff --git a/programs/rpcss/epmp.c b/programs/rpcss/epmp.c
index 2eb6039..3243192 100644
--- a/programs/rpcss/epmp.c
+++ b/programs/rpcss/epmp.c
@@ -165,6 +165,11 @@ void __cdecl ept_delete(handle_t h,
if (rpc_status != RPC_S_OK)
break;
entry = find_ept_entry(&iface, &syntax, protseq, endpoint, address, &entries[i].object);
+
+ I_RpcFree(protseq);
+ I_RpcFree(endpoint);
+ I_RpcFree(address);
+
if (entry)
delete_registered_ept_entry(entry);
else
@@ -172,9 +177,6 @@ void __cdecl ept_delete(handle_t h,
*status = EPT_S_NOT_REGISTERED;
break;
}
- I_RpcFree(protseq);
- I_RpcFree(endpoint);
- I_RpcFree(address);
}
LeaveCriticalSection(&csEpm);
More information about the wine-cvs
mailing list