W
Wizou
i'm using .NET 2.0, and i've made a lot of tests
i've come to the conclusion that TCP servers (tcplistener), started by
a father process, are somewhat inherited by child processes if using
UseShellExecute = false
why is that ?
try it ! even if the TcpListener is started *after* the
childProcess.Start, the TCP server is still registered in netstat -ao
and connectable with telnet, even if the father process stopped (or
crashed, or was killed)
As long as the child process is living, the TCP server is there, with
the old PID of the father process
When the child process ends, the TCP server disappears and telnet
connection is stopped
This is annoying because it prevent another app from listening on this
port (for example, if you stopped debugging in Visual and you want to
restart debugging your app)
can someone explain this? or is this a bug of .NET 2.0 beta ?
thanks
i've come to the conclusion that TCP servers (tcplistener), started by
a father process, are somewhat inherited by child processes if using
UseShellExecute = false
why is that ?
try it ! even if the TcpListener is started *after* the
childProcess.Start, the TCP server is still registered in netstat -ao
and connectable with telnet, even if the father process stopped (or
crashed, or was killed)
As long as the child process is living, the TCP server is there, with
the old PID of the father process
When the child process ends, the TCP server disappears and telnet
connection is stopped
This is annoying because it prevent another app from listening on this
port (for example, if you stopped debugging in Visual and you want to
restart debugging your app)
can someone explain this? or is this a bug of .NET 2.0 beta ?
thanks