diff --git a/websocket-sharp/Net/RequestStream.cs b/websocket-sharp/Net/RequestStream.cs index 2129c553..8cf63669 100644 --- a/websocket-sharp/Net/RequestStream.cs +++ b/websocket-sharp/Net/RequestStream.cs @@ -252,8 +252,11 @@ namespace WebSocketSharp.Net public override int Read (byte[] buffer, int offset, int count) { - if (_disposed) - throw new ObjectDisposedException (GetType ().ToString ()); + if (_disposed) { + var name = GetType ().ToString (); + + throw new ObjectDisposedException (name); + } if (buffer == null) throw new ArgumentNullException ("buffer");