mirror of
https://github.com/2dust/v2rayN.git
synced 2026-11-13 07:55:01 +03:00
Adding OSPlatform Processing
This commit is contained in:
@@ -5,6 +5,7 @@ using System.Net;
|
||||
using System.Net.NetworkInformation;
|
||||
using System.Net.Sockets;
|
||||
using System.Reflection;
|
||||
using System.Runtime.InteropServices;
|
||||
using System.Security.Cryptography;
|
||||
using System.Text;
|
||||
using System.Text.RegularExpressions;
|
||||
@@ -703,6 +704,18 @@ namespace ServiceLib.Common
|
||||
return systemHosts;
|
||||
}
|
||||
|
||||
public static string GetExeName(string name)
|
||||
{
|
||||
if (RuntimeInformation.IsOSPlatform(OSPlatform.Windows))
|
||||
{
|
||||
return $"{name}.exe";
|
||||
}
|
||||
else
|
||||
{
|
||||
return name;
|
||||
}
|
||||
}
|
||||
|
||||
#endregion 杂项
|
||||
|
||||
#region TempPath
|
||||
|
||||
Reference in New Issue
Block a user