mirror of
https://github.com/snltty/linker.git
synced 2025-12-18 23:38:11 +08:00
托盘和服务更新
This commit is contained in:
@@ -100,6 +100,19 @@ namespace linker.service
|
||||
proc?.Dispose();
|
||||
|
||||
foreach (var item in Process.GetProcessesByName(mainExeName))
|
||||
{
|
||||
try
|
||||
{
|
||||
item.Close();
|
||||
item.WaitForExit(TimeSpan.FromMilliseconds(2000));
|
||||
item.Kill();
|
||||
}
|
||||
catch (Exception)
|
||||
{
|
||||
}
|
||||
}
|
||||
|
||||
foreach (var item in Process.GetProcessesByName("tun2socks"))
|
||||
{
|
||||
item.Kill();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user