mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-01-29 17:40:42 +00:00
making string conversions explicit
This commit is contained in:
parent
bf109dc6c9
commit
aebca1a085
@ -405,7 +405,7 @@ nsWalletlibService::WALLET_Encrypt (const PRUnichar *text, char **crypt) {
|
||||
|
||||
NS_IMETHODIMP
|
||||
nsWalletlibService::WALLET_Decrypt (const char *crypt, PRUnichar **text) {
|
||||
nsAutoString cryptAutoString = crypt;
|
||||
nsAutoString cryptAutoString; cryptAutoString.AssignWithConversion(crypt);
|
||||
nsAutoString textAutoString;
|
||||
PRBool rv = ::Wallet_Decrypt(cryptAutoString, textAutoString);
|
||||
*text = textAutoString.ToNewUnicode();
|
||||
|
@ -626,7 +626,7 @@ nsProfileAccess::RemoveSubTree(const PRUnichar* profileName)
|
||||
else
|
||||
mNumProfiles--;
|
||||
|
||||
if (mCurrentProfile.Equals(profileName))
|
||||
if (mCurrentProfile.EqualsWithConversion(profileName))
|
||||
{
|
||||
mCurrentProfile.SetLength(0);
|
||||
}
|
||||
@ -709,7 +709,7 @@ nsProfileAccess::FindProfileIndex(const PRUnichar* profileName)
|
||||
{
|
||||
ProfileStruct* profileItem = (ProfileStruct *) (mProfiles->ElementAt(index));
|
||||
|
||||
if(profileItem->profileName.Equals(profileName))
|
||||
if(profileItem->profileName.EqualsWithConversion(profileName))
|
||||
{
|
||||
retval = index;
|
||||
break;
|
||||
@ -991,7 +991,7 @@ nsProfileAccess::ProfileExists(const PRUnichar *profileName)
|
||||
for (PRInt32 index=0; index < mCount; index++)
|
||||
{
|
||||
ProfileStruct* profileItem = (ProfileStruct *) (mProfiles->ElementAt(index));
|
||||
if (profileItem->profileName.Equals(profileName))
|
||||
if (profileItem->profileName.EqualsWithConversion(profileName))
|
||||
{
|
||||
exists = PR_TRUE;
|
||||
break;
|
||||
|
Loading…
x
Reference in New Issue
Block a user