From 97c6db0e798e6ac5cfd0e95b3224b2fae6b026d2 Mon Sep 17 00:00:00 2001 From: George Hazan Date: Thu, 14 Mar 2024 15:50:08 +0300 Subject: code cleaning --- plugins/Msg_Export/src/utils.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'plugins/Msg_Export') diff --git a/plugins/Msg_Export/src/utils.cpp b/plugins/Msg_Export/src/utils.cpp index 6d6f1a5172..071d2ae43f 100644 --- a/plugins/Msg_Export/src/utils.cpp +++ b/plugins/Msg_Export/src/utils.cpp @@ -474,9 +474,8 @@ void ReplaceDefines(MCONTACT hContact, wstring &sTarget) ReplaceAllNoColon(sTarget, L"%group%", sGroup); } - // We can't replace the : here because if the user uses C:\... in the file path - // this will also be replaced - string::size_type nCur = 0; + // we don't touch the leading colon and \\ either + string::size_type nCur = 2; while ((nCur = sTarget.find_first_of(L"/*?:<>|\"", nCur)) != sTarget.npos) sTarget[nCur] = cBadCharReplace; } -- cgit v1.2.3