,Hi
.I am using GRPC 1.4.0 on windows
:According the code, accepting new connection goes like this
:Thread1
...
closure_exec_thread_func
Listen
AcceptEx with ovelapped
the sockets are associated with g_iocp.
thread 2:
...
grpc_iocp_work
GetQueuedCompletionStatus
.thread 2 might be executed after thread 1 is terminated
:according to msdn reference about acceptex
Note All I/O initiated by a given thread is canceled when that thread exits. For overlapped sockets, pending asynchronous operations can fail if the thread is closed before the operations complete. See ExitThread for more information.
.When activating AcceptEx at thread 1, it creates pending asynchronous operations
At thread 2 we query for information regarding this pendin io operation.
?Shouldnt there be a problem with this flow
I do know that such a flow (Thread 1: assynchronous accept exit, Thread 2: GetQueuedCompletionStatus) might cause a problem in windows XP
Thx,
Moshe.