From 3cebf492d14c94f5ce6b84ee62a3b66c4f502852 Mon Sep 17 00:00:00 2001 From: DHR60 <192860629+DHR60@users.noreply.github.com> Date: Tue, 23 Jun 2026 05:46:36 +0000 Subject: [PATCH] Fix (#9614) --- v2rayN/ServiceLib/Common/Utils.cs | 23 +++++++++++++++++++ .../ViewModels/RoutingRuleDetailsViewModel.cs | 2 +- 2 files changed, 24 insertions(+), 1 deletion(-) diff --git a/v2rayN/ServiceLib/Common/Utils.cs b/v2rayN/ServiceLib/Common/Utils.cs index 8237e952..7318114b 100644 --- a/v2rayN/ServiceLib/Common/Utils.cs +++ b/v2rayN/ServiceLib/Common/Utils.cs @@ -324,6 +324,29 @@ public class Utils .ReplaceLineBreaks(","); } + public static string ParseProcess(string text) + { + if (text.IsNullOrEmpty()) + { + return string.Empty; + } + if (text.StartsWith('"')) + { + text = text[1..]; + } + if (text.EndsWith('"')) + { + text = text[..^1]; + } + return List2String(text.Replace(",", ",") + .Replace("\\", "/") + .ReplaceLineBreaks(",") + .Split(',', StringSplitOptions.RemoveEmptyEntries) + .Select(x => x.TrimEx()) + .Where(x => x.IsNotEmpty()) + .ToList()); + } + public static List GetEnumNames() where TEnum : Enum { return Enum.GetValues(typeof(TEnum)) diff --git a/v2rayN/ServiceLib/ViewModels/RoutingRuleDetailsViewModel.cs b/v2rayN/ServiceLib/ViewModels/RoutingRuleDetailsViewModel.cs index 788e6e92..e0016911 100644 --- a/v2rayN/ServiceLib/ViewModels/RoutingRuleDetailsViewModel.cs +++ b/v2rayN/ServiceLib/ViewModels/RoutingRuleDetailsViewModel.cs @@ -57,7 +57,7 @@ public class RoutingRuleDetailsViewModel : MyReactiveObject { Domain = Utils.Convert2Comma(Domain); IP = Utils.Convert2Comma(IP); - Process = Utils.Convert2Comma(Process); + Process = Utils.ParseProcess(Process); if (AutoSort) {