Block TcpipServer.StopListening until socket is used

In some cases there was still _listener.AcceptSocket waiting even when
_listener.Stop was called before. That causes problems when we tried to
start new TcpipServer listening on the same port.
Merge pull request #9 from stej/master

Block TcpipServer.StopListening until socket is used