4.49 beta

This commit is contained in:
Igor Pavlov
2007-07-11 00:00:00 +00:00
committed by Kornel Lesiński
parent fd8b1d78b4
commit 7038848692
44 changed files with 1600 additions and 220 deletions
+16 -1
View File
@@ -3,6 +3,21 @@
#include "StdAfx.h"
#include "ExtractingFilePath.h"
static UString ReplaceIncorrectChars(const UString &s)
{
UString res;
for (int i = 0; i < s.Length(); i++)
{
wchar_t c = s[i];
#ifdef _WIN32
if (c < 0x20 || c == '*' || c == '?' || c == '<' || c == '>' || c == '|' || c == ':' || c == '"')
c = '_';
#endif
res += c;
}
return res;
}
static void ReplaceDisk(UString &s)
{
int i;
@@ -58,7 +73,7 @@ UString GetCorrectPath(const UString &path)
result.Replace(L"../", L"");
ReplaceDisk(result);
return result;
return ReplaceIncorrectChars(result);
}
void MakeCorrectPath(UStringVector &pathParts)