[Modify] Polish it
This commit is contained in:
parent
e268168e6a
commit
2974c5fa22
@ -112,8 +112,11 @@ namespace WebSocketSharp.Net
|
|||||||
|
|
||||||
var path = pref.Path;
|
var path = pref.Path;
|
||||||
|
|
||||||
if (path.IndexOf ('%') != -1)
|
if (path.IndexOf ('%') != -1) {
|
||||||
throw new HttpListenerException (87, "Includes an invalid path.");
|
var msg = "The URI prefix includes an invalid path.";
|
||||||
|
|
||||||
|
throw new HttpListenerException (87, msg);
|
||||||
|
}
|
||||||
|
|
||||||
if (path.IndexOf ("//", StringComparison.Ordinal) != -1)
|
if (path.IndexOf ("//", StringComparison.Ordinal) != -1)
|
||||||
throw new HttpListenerException (87, "Includes an invalid path.");
|
throw new HttpListenerException (87, "Includes an invalid path.");
|
||||||
|
Loading…
Reference in New Issue
Block a user