防止日志打印失败造成的程序闪退
This commit is contained in:
parent
836a90800b
commit
e0ba6acd60
|
@ -69,6 +69,8 @@ namespace N_m3u8DL_RE.Common.Log
|
|||
}
|
||||
|
||||
private static void HandleLog(string write, string subWrite = "")
|
||||
{
|
||||
try
|
||||
{
|
||||
if (subWrite == "")
|
||||
{
|
||||
|
@ -98,6 +100,11 @@ namespace N_m3u8DL_RE.Common.Log
|
|||
}
|
||||
}
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
Console.WriteLine("Failed to write: " + write);
|
||||
}
|
||||
}
|
||||
|
||||
private static string ReplaceVars(string data, params object[] ps)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue