diff --git a/mailnews/imap/src/nsImapIncomingServer.cpp b/mailnews/imap/src/nsImapIncomingServer.cpp index 76e97417739e..5a87762579cc 100644 --- a/mailnews/imap/src/nsImapIncomingServer.cpp +++ b/mailnews/imap/src/nsImapIncomingServer.cpp @@ -1333,6 +1333,15 @@ NS_IMETHODIMP nsImapIncomingServer::PossibleImapMailbox(const char *folderPath, else { rv = ConvertFolderName(onlineName.get(), getter_Copies(convertedName)); + + //make sure rv value is not crunched, it is used to SetPrettyName + nsXPIDLCString redirectorType; + GetRedirectorType(getter_Copies(redirectorType)); //Sent mail folder as per netscape webmail and aol server + if ((redirectorType.Equals(NS_LITERAL_CSTRING("aol")) && convertedName.Equals(NS_LITERAL_STRING("Sent Mail"))) || + (redirectorType.Equals(NS_LITERAL_CSTRING("netscape")) && onlineName.Equals(NS_LITERAL_CSTRING("Sent")))) + //we know that we don't allowConversion for netscape webmail so just use the onlineName + child->SetFlag(MSG_FOLDER_FLAG_SENTMAIL); + if (NS_SUCCEEDED(rv)) child->SetPrettyName(convertedName); }