Bug #99101: In RenameLeaf(), unescape the folder name before searching for hierarchy delimiter (to figure out parent pathname). r=naving, sr=bienvenu.

This commit is contained in:
cavin%netscape.com 2001-09-12 20:14:35 +00:00
Родитель 4825371fbf
Коммит 523d47fdba
1 изменённых файлов: 4 добавлений и 2 удалений

Просмотреть файл

@ -2387,8 +2387,10 @@ nsImapService::RenameLeaf(nsIEventQueue* eventQueue, nsIMsgFolder* srcFolder,
char *utfNewName = CreateUtf7ConvertedStringFromUnicode( newLeafName); char *utfNewName = CreateUtf7ConvertedStringFromUnicode( newLeafName);
nsCAutoString cStrFolderName(NS_STATIC_CAST(const char *, folderName)); nsCAutoString cStrFolderName(NS_STATIC_CAST(const char *, folderName));
PRInt32 leafNameStart = // Unescape the name before looking for parent path
nsUnescape(NS_CONST_CAST(char*, cStrFolderName.get()));
PRInt32 leafNameStart =
cStrFolderName.RFindChar(hierarchySeparator); cStrFolderName.RFindChar(hierarchySeparator);
if (leafNameStart != -1) if (leafNameStart != -1)
{ {