diff --git a/websocket-sharp/Net/HttpListenerRequest.cs b/websocket-sharp/Net/HttpListenerRequest.cs index 2ee9382f..6f24f5d9 100644 --- a/websocket-sharp/Net/HttpListenerRequest.cs +++ b/websocket-sharp/Net/HttpListenerRequest.cs @@ -829,6 +829,7 @@ namespace WebSocketSharp.Net if (!method.IsHttpMethod (ver)) { _context.ErrorMessage = "Invalid request line (method)"; + _context.ErrorStatusCode = 501; return; }