[Modify] Add it

master
sta 9 years ago
parent 3984739b5d
commit 7a6b2e3e5a

@ -113,6 +113,23 @@ namespace WebSocketSharp.Server
return buff.ToString ().Replace ('\\', '/'); return buff.ToString ().Replace ('\\', '/');
} }
private static bool tryReadFile (string path, out byte[] contents)
{
contents = null;
if (!File.Exists (path))
return false;
try {
contents = File.ReadAllBytes (path);
}
catch {
return false;
}
return true;
}
#endregion #endregion
#region Public Methods #region Public Methods

Loading…
Cancel
Save