I'm using udp at the moment, and every now and again the UdpClient i'm using decides to throw a socket exception with error code 10054. Google tells me this:

Socket error 10054 may be the result of the remote server or some other piece of network equipment forcibly closing or resetting the connection
But this is UDP. There is no connection. What exactly is causing this, and how exactly can i avoid it? My temporary fix is to dispose the existing udpclient and instantiate another one, but that seems a bit stupid. The offending code is here:

Code:
        private void EndReceive(IAsyncResult result)
        {
            try
            {
                IPEndPoint e = new IPEndPoint(IPAddress.Any, endpoint.Port);
                byte[] buffer = client.EndReceive(result, ref e);

                // Fire the event to indicate i've received a message
                if (MessageReceived != null)
                    MessageReceived(buffer, e);
            }
            catch
            {
                // ignore
            }
            
            // This is the part which throws an exception randomly
            client.BeginReceive(EndReceive, null);
        }