On 17/12/2014 15:47, Chris Hegarty wrote:
A socket connection which is returned by ServerSocket.accept() is
inherited by a child process. The expected behavior is that the socket
connection is not inherited by the child process. This is an oversight
in the original implementation, that only sets HANDLE_FLAG_INHERIT for
newly created sockets.
I assume the real issue here is that CreateProcess is being called with
bInheritHandles set to TRUE, I think we might have to dig into the
reasons for that as I'm sure it has been looked at many times. There is
also code in the Process implementation to toggle the inheritance
setting prior to calling CreateProcess and I'm also curious why that
isn't working.
So while you proposed change is benign, I think there may be more going
on here that we should look into.
-Alan.