From 9aa1cc1cc2631dd852a56c338f0f9e3413580f2a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A4=A7=E7=9F=B3=E5=A4=B4?= Date: Wed, 10 Jul 2024 17:24:33 +0800 Subject: [PATCH] =?UTF-8?q?[fix]=E6=9B=B4=E6=96=B0=E5=90=8E=E9=87=8D?= =?UTF-8?q?=E5=90=AF=E6=8B=89=E8=B5=B7=E5=BA=94=E7=94=A8=E6=97=B6=EF=BC=8C?= =?UTF-8?q?=E5=8F=82=E6=95=B0=E6=90=BA=E5=B8=A6=E6=AD=A3=E7=A1=AE=E7=9A=84?= =?UTF-8?q?=E5=91=BD=E4=BB=A4=E8=A1=8C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- NewLife.Remoting/Clients/ClientBase.cs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/NewLife.Remoting/Clients/ClientBase.cs b/NewLife.Remoting/Clients/ClientBase.cs index db8f9fd..7f26685 100644 --- a/NewLife.Remoting/Clients/ClientBase.cs +++ b/NewLife.Remoting/Clients/ClientBase.cs @@ -820,7 +820,11 @@ protected virtual void Restart(Upgrade upgrade) if (name.IsNullOrEmpty()) return; // 重新拉起进程 - var rs = upgrade.Run(name, $"-upgrade {Environment.CommandLine}"); + var args = Environment.GetCommandLineArgs(); + if (args == null || args.Length == 0) args = new String[1]; + args[0] = "-upgrade"; + + var rs = upgrade.Run(name, args.Join(" ")); if (rs) {