From aaf9ab849530779b1b48ad4d995eaabaf85c4657 Mon Sep 17 00:00:00 2001 From: sta Date: Sun, 31 Jan 2021 21:57:50 +0900 Subject: [PATCH] [Modify] Polish it --- websocket-sharp/Net/RequestStream.cs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/websocket-sharp/Net/RequestStream.cs b/websocket-sharp/Net/RequestStream.cs index 0ed6c6ee..40381779 100644 --- a/websocket-sharp/Net/RequestStream.cs +++ b/websocket-sharp/Net/RequestStream.cs @@ -125,8 +125,11 @@ namespace WebSocketSharp.Net if (buffer == null) throw new ArgumentNullException ("buffer"); - if (offset < 0) - throw new ArgumentOutOfRangeException ("offset", "A negative value."); + if (offset < 0) { + var msg = "A negative value."; + + throw new ArgumentOutOfRangeException ("offset", msg); + } if (count < 0) throw new ArgumentOutOfRangeException ("count", "A negative value.");