From 06bb079e7d0c83ca79f55d1d18ab6f8f87a39e48 Mon Sep 17 00:00:00 2001 From: timerix Date: Wed, 17 Aug 2022 03:14:45 +0600 Subject: [PATCH] logfile name generation fixed again --- DTLib/Logging/FileLogger.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/DTLib/Logging/FileLogger.cs b/DTLib/Logging/FileLogger.cs index 26cfe0d..0a1be81 100644 --- a/DTLib/Logging/FileLogger.cs +++ b/DTLib/Logging/FileLogger.cs @@ -11,7 +11,8 @@ public class FileLogger : IDisposable } public FileLogger(string dir, string programName) - : this($"{dir}{Путь.Разд}{programName}_{DateTime.Now}.log".Replace(':', '-').Replace(' ', '_')) { } + : this($"{dir}{Путь.Разд}{programName}_{DateTime.Now.ToString(CultureInfo.InvariantCulture)}.log" + .Replace(':', '-').Replace(' ', '_')) { } public string LogfileName { get; protected set; } public System.IO.FileStream LogfileStream { get; protected set; }