From 6bc69b17cf619d9054fea4012ada1ff42bc414ea Mon Sep 17 00:00:00 2001 From: Jack251970 <1160210343@qq.com> Date: Fri, 14 Mar 2025 11:21:07 +0800 Subject: [PATCH] Do not allow kill FL process --- Plugins/Flow.Launcher.Plugin.ProcessKiller/ProcessHelper.cs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/Plugins/Flow.Launcher.Plugin.ProcessKiller/ProcessHelper.cs b/Plugins/Flow.Launcher.Plugin.ProcessKiller/ProcessHelper.cs index c603fba09..1538f71dd 100644 --- a/Plugins/Flow.Launcher.Plugin.ProcessKiller/ProcessHelper.cs +++ b/Plugins/Flow.Launcher.Plugin.ProcessKiller/ProcessHelper.cs @@ -31,7 +31,10 @@ namespace Flow.Launcher.Plugin.ProcessKiller "explorer" }; - private bool IsSystemProcess(Process p) => _systemProcessList.Contains(p.ProcessName.ToLower()); + private const string FlowLauncherProcessName = "Flow.Launcher"; + + private bool IsSystemProcess(Process p) => _systemProcessList.Contains(p.ProcessName.ToLower()) || + string.Compare(p.ProcessName, FlowLauncherProcessName, StringComparison.OrdinalIgnoreCase) == 0; /// /// Returns a ProcessResult for evey running non-system process whose name matches the given searchTerm