diff --git a/v2rayN/PacLib/PacHandler.cs b/v2rayN/PacLib/PacHandler.cs index 2e32f1f7..c8c326d7 100644 --- a/v2rayN/PacLib/PacHandler.cs +++ b/v2rayN/PacLib/PacHandler.cs @@ -77,8 +77,9 @@ public class PacHandler stream.Flush(); }); } - catch (Exception e) + catch { + // ignored } } }, TaskCreationOptions.LongRunning); @@ -86,17 +87,16 @@ public class PacHandler public static void Stop() { - if (_tcpListener != null) + if (_tcpListener == null) return; + try { - try - { - _isRunning = false; - _tcpListener.Stop(); - _tcpListener = null; - } - catch (Exception e) - { - } + _isRunning = false; + _tcpListener.Stop(); + _tcpListener = null; + } + catch + { + // ignored } } } \ No newline at end of file diff --git a/v2rayN/ServiceLib/Services/UpdateService.cs b/v2rayN/ServiceLib/Services/UpdateService.cs index 179da11c..d93407a2 100644 --- a/v2rayN/ServiceLib/Services/UpdateService.cs +++ b/v2rayN/ServiceLib/Services/UpdateService.cs @@ -503,6 +503,11 @@ namespace ServiceLib.Services } } + var path = Utils.GetBinPath("srss"); + if (!Directory.Exists(path)) + { + Directory.CreateDirectory(path); + } foreach (var item in geoipFiles.Distinct()) { await UpdateSrsFile("geoip", item, config, updateFunc);