Skip to content

Commit

Permalink
Merge remote-tracking branch 'ssvine/fix-log-time-format'
Browse files Browse the repository at this point in the history
* ssvine/fix-log-time-format:
  Do not duplicate time in logs
  • Loading branch information
michaellukashov committed May 5, 2024
2 parents 3258af9 + b030565 commit cb98a09
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/core/SessionInfo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -881,9 +881,10 @@ void TSessionLog::DoAddToSelf(TLogLineType Type, const UnicodeString & ALine)

if (FLogger != nullptr)
{
const UTF8String UtfLine = UTF8String(UnicodeString(1, LogLineMarks[Type]) + " " + TrimRight(ALine)); // without timestamp
#if defined(__BORLANDC__)
const UnicodeString Timestamp = FormatDateTime(L" yyyy-mm-dd hh:nn:ss.zzz ", Now());
const UTF8String UtfLine = UTF8String(UnicodeString(1, LogLineMarks[Type]) + Timestamp + TrimRight(ALine)); // + "\r\n";
#if defined(__BORLANDC__)
for (int32_t Index = 1; Index <= UtfLine.Length(); Index++)
{
if ((UtfLine[Index] == '\n') &&
Expand Down

0 comments on commit cb98a09

Please sign in to comment.