From 04e7c56ba71c698d70c3a9c8b8a8d03d255f1381 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E9=BE=99=E8=85=BE=E7=8C=AB=E8=B7=83?= <1043137532@qq.com> Date: Wed, 20 May 2026 22:40:24 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=BD=93=E7=BC=BA=E5=B0=91=E6=9F=90?= =?UTF-8?q?=E4=B8=AA=E6=96=87=E4=BB=B6=E5=A4=B9=E6=97=B6=EF=BC=8CGetFolder?= =?UTF-8?q?Path=20=E4=BC=9A=E8=BF=94=E5=9B=9E=E7=A9=BA=E5=AD=97=E7=AC=A6?= =?UTF-8?q?=E4=B8=B2=EF=BC=8C=E5=AF=BC=E8=87=B4=E5=AE=89=E5=85=A8=E6=A3=80?= =?UTF-8?q?=E6=9F=A5=E5=BC=82=E5=B8=B8=EF=BC=88close=20Meloong-Git/PCL#863?= =?UTF-8?q?6=EF=BC=8C@qwer154899=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Shared/Utils/CryptographyUtils.cs | 2 +- Shared/Utils/DirectoryUtils.cs | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/Shared/Utils/CryptographyUtils.cs b/Shared/Utils/CryptographyUtils.cs index 850fb4b..074ff4d 100644 --- a/Shared/Utils/CryptographyUtils.cs +++ b/Shared/Utils/CryptographyUtils.cs @@ -101,7 +101,7 @@ public static class CryptographyUtils { #region ECDSA /// - /// 未指定公钥时使用的默认 ECDSA P-256 公钥。 + /// 未指定公钥时的默认 ECDSA P-256 公钥。 /// public static string defaultEcdsaPublicKey = "RUNTMSAAAAC4QTUNAewh23Q4Q6koHkyIrDIIZUSbua23sf2DiZmIRwSzadISDRyTVTbuWniH3KR7rKj8XBsabms1be6i3c+S"; diff --git a/Shared/Utils/DirectoryUtils.cs b/Shared/Utils/DirectoryUtils.cs index 0a681c3..29f28e0 100644 --- a/Shared/Utils/DirectoryUtils.cs +++ b/Shared/Utils/DirectoryUtils.cs @@ -161,6 +161,7 @@ public static class DirectoryUtils { Environment.GetFolderPath(Environment.SpecialFolder.MyDocuments), Environment.GetFolderPath(Environment.SpecialFolder.Windows), Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.UserProfile), "Downloads") // 下载文件夹没有 SpecialFolder 枚举 - }.Select(f => PathUtils.ForCompare(f)))); + }.Where(f => f.Contains(Path.VolumeSeparatorChar)) // 当缺少某个文件夹时,GetFolderPath 会返回空字符串(#8636) + .Select(f => PathUtils.ForCompare(f)))); }