[Mono-dev] BeginTryReceiveRequest and Socket error handling?

Rob Wilkens robwilkens at gmail.com
Wed Jun 27 13:09:36 UTC 2012


This code:
                                         try {
                                                return TryReceiveRequest
(tout, out ctx);
                                        } finally {
                                                lock (async_result_lock) {
                                                       
CurrentAsyncResult = null;
                                                       
CurrentAsyncThread = null;
                                                }
                                        }

In ReplyChannelBase.cs, should probably catch and _ignore_
SocketException, perhaps after dumping a debug message, if not catch
other errors, and then go to the finally.  It's already setting the
result to null on failure, but this is continuuing to go on to crash
because the message dies not appear to be handled further upstream.

This is before "} finally {" do something like:

                       } catch (SocketException ex) {
                                //ignore this or print debug message
becuase it sets the result to null in finally
      
Anyone have opinions on this?

-Rob


More information about the Mono-devel-list mailing list