small changes to clients of string converting APIs

This commit is contained in:
scc%netscape.com 2000-03-26 12:14:14 +00:00
Родитель 1381293dea
Коммит baf5b30589
3 изменённых файлов: 9 добавлений и 9 удалений

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

@ -220,7 +220,7 @@ NS_IMETHODIMP nsMsgDBFolder::GetCharset(PRUnichar * *aCharset)
if(!aCharset)
return NS_ERROR_NULL_POINTER;
if(mCharset == "")
if(mCharset.IsEmpty())
{
NS_WITH_SERVICE(nsIPref, prefs, kPrefServiceCID, &rv);

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

@ -1868,7 +1868,7 @@ NS_IMETHODIMP nsMsgFolder::GetNewMessagesNotificationDescription(PRUnichar * *aD
nsXPIDLString folderName;
rv = GetPrettyName(getter_Copies(folderName));
if (NS_SUCCEEDED(rv) && folderName)
description = folderName;
description.Assign(folderName);
}
// append the server name
@ -1879,7 +1879,7 @@ NS_IMETHODIMP nsMsgFolder::GetNewMessagesNotificationDescription(PRUnichar * *aD
// in case the above failed
if (!(mFlags & MSG_FOLDER_FLAG_INBOX))
description += " on ";
description += serverName;
description.Append(serverName);
}
}
*aDescription = description.ToNewUnicode();

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

@ -167,7 +167,7 @@ nsMsgIncomingServer::GetServerURI(char **aResult)
rv = GetLocalStoreType(getter_Copies(localStoreType));
if (NS_FAILED(rv)) return rv;
uri += localStoreType;
uri.Append(localStoreType);
uri += "://";
nsXPIDLCString username;
@ -179,7 +179,7 @@ nsMsgIncomingServer::GetServerURI(char **aResult)
nsEscape(username, url_XAlphas);
// nsEscape(username, url_Path);
// not all servers have a username
uri += escapedUsername;
uri.Append(escapedUsername);
uri += '@';
}
@ -191,7 +191,7 @@ nsMsgIncomingServer::GetServerURI(char **aResult)
*((char **)getter_Copies(escapedHostname)) =
nsEscape(hostname, url_Path);
// not all servers have a hostname
uri += escapedHostname;
uri.Append(escapedHostname);
}
*aResult = uri.ToNewCString();
@ -495,7 +495,7 @@ nsMsgIncomingServer::GetPrettyName(PRUnichar **retval) {
if (NS_FAILED(rv)) return rv;
if ((const char*)username &&
PL_strcmp((const char*)username, "")!=0) {
prettyName = username;
prettyName.Assign(username);
prettyName += " on ";
}
@ -679,7 +679,7 @@ nsMsgIncomingServer::SetDefaultLocalPath(nsIFileSpec *aDefaultLocalPath)
GetType(getter_Copies(type));
nsCAutoString progid(NS_MSGPROTOCOLINFO_PROGID_PREFIX);
progid += type;
progid.Append(type);
NS_WITH_SERVICE(nsIMsgProtocolInfo, protocolInfo, progid, &rv);
if (NS_FAILED(rv)) return rv;
@ -708,7 +708,7 @@ nsMsgIncomingServer::GetLocalPath(nsIFileSpec **aLocalPath)
GetType(getter_Copies(type));
nsCAutoString progid(NS_MSGPROTOCOLINFO_PROGID_PREFIX);
progid += type;
progid.Append(type);
NS_WITH_SERVICE(nsIMsgProtocolInfo, protocolInfo, progid, &rv);
if (NS_FAILED(rv)) return rv;