[PATCH] rpcrt4: wait_async_request: return error if we received an error
Marcus Meissner
marcus at jet.franken.de
Sat Sep 29 04:44:17 CDT 2012
Hi,
Various coverity issues complain about user-after-free scenarios,
all involving this code path.
I strongly think if call_ret signals error, we also need to return
an error condition to avoid the callers from proceeding as if nothing
happened.
Ciao, Marcus
---
dlls/rpcrt4/rpc_transport.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/dlls/rpcrt4/rpc_transport.c b/dlls/rpcrt4/rpc_transport.c
index 686ce68..e572b78 100644
--- a/dlls/rpcrt4/rpc_transport.c
+++ b/dlls/rpcrt4/rpc_transport.c
@@ -1882,7 +1882,7 @@ static RPC_STATUS wait_async_request(RpcHttpAsyncData *async_data, BOOL call_ret
if(call_ret) {
RpcHttpAsyncData_Release(async_data);
- return RPC_S_OK;
+ return call_ret; /* The Http* status codes map into the RPC_S namespace */
}
if(GetLastError() != ERROR_IO_PENDING) {
--
1.7.3.4
More information about the wine-patches
mailing list