[Modify] It throws exception

This commit is contained in:
sta 2017-06-03 16:22:20 +09:00
parent c1551b8b6f
commit aac634848e

View File

@ -1059,13 +1059,14 @@ namespace WebSocketSharp.Server
/// <summary>
/// Starts receiving the HTTP requests.
/// </summary>
/// <exception cref="InvalidOperationException">
/// There is no certificate.
/// </exception>
public void Start ()
{
var msg = checkIfCertificateExists ();
if (msg != null) {
_log.Error (msg);
return;
}
string msg;
if (!checkCertificate (out msg))
throw new InvalidOperationException (msg);
start ();
}