From 1e70d960ba28d0cdd33db4ac598561b009f12952 Mon Sep 17 00:00:00 2001 From: Matt Nadareski Date: Fri, 10 Sep 2021 13:59:35 -0700 Subject: [PATCH] Remove unnecessary trims --- BurnOutSharp/ProtectionType/SolidShield.cs | 2 +- BurnOutSharp/ProtectionType/StarForce.cs | 2 +- BurnOutSharp/Scanner.cs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/BurnOutSharp/ProtectionType/SolidShield.cs b/BurnOutSharp/ProtectionType/SolidShield.cs index c6d2126f..aecbbf8b 100644 --- a/BurnOutSharp/ProtectionType/SolidShield.cs +++ b/BurnOutSharp/ProtectionType/SolidShield.cs @@ -52,7 +52,7 @@ namespace BurnOutSharp.ProtectionType if (sections == null) return null; - string name = Utilities.GetFileDescription(pex)?.Trim(); + string name = Utilities.GetFileDescription(pex); if (!string.IsNullOrWhiteSpace(name) && name.StartsWith("DVM Library", StringComparison.OrdinalIgnoreCase)) return $"SolidShield {Utilities.GetFileVersion(pex)}"; else if (!string.IsNullOrWhiteSpace(name) && name.StartsWith("Solidshield Activation Library", StringComparison.OrdinalIgnoreCase)) diff --git a/BurnOutSharp/ProtectionType/StarForce.cs b/BurnOutSharp/ProtectionType/StarForce.cs index 492155b3..e3527562 100644 --- a/BurnOutSharp/ProtectionType/StarForce.cs +++ b/BurnOutSharp/ProtectionType/StarForce.cs @@ -28,7 +28,7 @@ namespace BurnOutSharp.ProtectionType return $"StarForce {Utilities.GetFileVersion(pex)}"; // TODO: Find what fvinfo field actually maps to this - name = Utilities.GetFileDescription(pex).Trim(); + name = Utilities.GetFileDescription(pex); if (!string.IsNullOrWhiteSpace(name) && name.Contains("Protected Module")) return $"StarForce 5"; diff --git a/BurnOutSharp/Scanner.cs b/BurnOutSharp/Scanner.cs index 3cd903ed..67c3b408 100644 --- a/BurnOutSharp/Scanner.cs +++ b/BurnOutSharp/Scanner.cs @@ -413,7 +413,7 @@ namespace BurnOutSharp #endregion } } - catch + catch (Exception ex) { Utilities.AppendToDictionary(protections, file, "[Exception opening file, please try again]"); }