mirror of
https://github.com/reactos/reactos.git
synced 2025-08-06 16:32:57 +00:00
[RPCRT4]
- do not wait for other threads in DLL_PROCESS_DETACH - fix handle leak - remove debug code svn path=/trunk/; revision=53271
This commit is contained in:
parent
3305cfabfb
commit
fd460fd4a1
2 changed files with 6 additions and 18 deletions
|
@ -1071,8 +1071,6 @@ void RPCRT4_destroy_all_protseqs(void)
|
||||||
EnterCriticalSection(&server_cs);
|
EnterCriticalSection(&server_cs);
|
||||||
LIST_FOR_EACH_ENTRY_SAFE(cps, cursor2, &protseqs, RpcServerProtseq, entry)
|
LIST_FOR_EACH_ENTRY_SAFE(cps, cursor2, &protseqs, RpcServerProtseq, entry)
|
||||||
{
|
{
|
||||||
if (listen_count != 0)
|
|
||||||
RPCRT4_sync_with_server_thread(cps);
|
|
||||||
destroy_serverprotoseq(cps);
|
destroy_serverprotoseq(cps);
|
||||||
}
|
}
|
||||||
LeaveCriticalSection(&server_cs);
|
LeaveCriticalSection(&server_cs);
|
||||||
|
|
|
@ -103,9 +103,6 @@
|
||||||
|
|
||||||
WINE_DEFAULT_DEBUG_CHANNEL(rpc);
|
WINE_DEFAULT_DEBUG_CHANNEL(rpc);
|
||||||
|
|
||||||
#undef ERR
|
|
||||||
#define ERR FIXME
|
|
||||||
|
|
||||||
static RPC_STATUS RPCRT4_SpawnConnection(RpcConnection** Connection, RpcConnection* OldConnection);
|
static RPC_STATUS RPCRT4_SpawnConnection(RpcConnection** Connection, RpcConnection* OldConnection);
|
||||||
|
|
||||||
/**** ncacn_np support ****/
|
/**** ncacn_np support ****/
|
||||||
|
@ -225,22 +222,14 @@ static RPC_STATUS rpcrt4_conn_open_pipe(RpcConnection *Connection, LPCSTR pname,
|
||||||
if (pipe != INVALID_HANDLE_VALUE) break;
|
if (pipe != INVALID_HANDLE_VALUE) break;
|
||||||
err = GetLastError();
|
err = GetLastError();
|
||||||
if (err == ERROR_PIPE_BUSY) {
|
if (err == ERROR_PIPE_BUSY) {
|
||||||
ERR("connection to %s failed, error=%x\n", pname, err);
|
TRACE("connection failed, error=%x\n", err);
|
||||||
return RPC_S_SERVER_TOO_BUSY;
|
return RPC_S_SERVER_TOO_BUSY;
|
||||||
}
|
}
|
||||||
if(wait) ERR("Waiting for pipe instance");
|
if (!wait || !WaitNamedPipeA(pname, NMPWAIT_WAIT_FOREVER)) {
|
||||||
if(wait)
|
|
||||||
{
|
|
||||||
if (!WaitNamedPipeA(pname, NMPWAIT_WAIT_FOREVER)) {
|
|
||||||
err = GetLastError();
|
err = GetLastError();
|
||||||
ERR("connection to %s failed, error=%x, wait %x\n", pname, err, wait);
|
WARN("connection failed, error=%x\n", err);
|
||||||
return RPC_S_SERVER_UNAVAILABLE;
|
return RPC_S_SERVER_UNAVAILABLE;
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
ERR("Pipe Instance Ready!!!!!!!!!!!!!!!!!!\n");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/* success */
|
/* success */
|
||||||
|
@ -469,6 +458,7 @@ static int rpcrt4_conn_np_write(RpcConnection *Connection,
|
||||||
bytes_left -= bytes_written;
|
bytes_left -= bytes_written;
|
||||||
buf += bytes_written;
|
buf += bytes_written;
|
||||||
}
|
}
|
||||||
|
CloseHandle(ovl.hEvent);
|
||||||
return ret ? count : -1;
|
return ret ? count : -1;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue