Browse Source

Give a more user friendly message when plugin program file does not exist

tags/4.2.1.0
celeron533 5 years ago
parent
commit
8da3f11d43
1 changed files with 5 additions and 0 deletions
  1. +5
    -0
      shadowsocks-csharp/Controller/Service/Sip003Plugin.cs

+ 5
- 0
shadowsocks-csharp/Controller/Service/Sip003Plugin.cs View File

@@ -94,6 +94,11 @@ namespace Shadowsocks.Controller.Service
return false;
}

if (!File.Exists(_pluginProcess.StartInfo.FileName))
{
throw new FileNotFoundException(I18N.GetString("Cannot find the plugin program file"), _pluginProcess.StartInfo.FileName);
}

var localPort = GetNextFreeTcpPort();
LocalEndPoint = new IPEndPoint(IPAddress.Loopback, localPort);



Loading…
Cancel
Save