Hmm. I'm having the same problem as KazoWar.
After looking at the logs, it appears that one of these lines hangs sometimes:
ReDim rr(511)
s = New Socket(AddressFamily.InterNetwork, SocketType.Dgram, ProtocolType.Udp)
s.Connect(DEFAULT_DNS_SERVER, 53)
s.Send(r, lngRcv, SocketFlags.None)
lngSnd = s.Receive(rr, SocketFlags.None)
ReDim Preserve rr(lngSnd)
Any ideas which one, or why it would be hanging? Would timing this section out be an effective solution?