Bug 1385340 - Port bug 1382563 to mailnews: Replace AssignWithConversion() with CopyASCIItoUTF16(). r=jorgk
authorRichard Marti <richard.marti@gmail.com>
Fri, 28 Jul 2017 17:53:51 +0200
changeset 28502 e852e28ef366d008ea8f449c8db4e63c29e8b229
parent 28501 8194b984c89175f2dd252932510227eda2590f6e
child 28503 3749d8c1fa1b10b7a73f624ea2ef851fa1eab668
push id1986
push userclokep@gmail.com
push dateWed, 02 Aug 2017 14:43:31 +0000
treeherdercomm-beta@b51c9adf2c9e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjorgk
bugs1385340, 1382563
Bug 1385340 - Port bug 1382563 to mailnews: Replace AssignWithConversion() with CopyASCIItoUTF16(). r=jorgk
mailnews/intl/nsCharsetConverterManager.cpp
--- a/mailnews/intl/nsCharsetConverterManager.cpp
+++ b/mailnews/intl/nsCharsetConverterManager.cpp
@@ -59,17 +59,17 @@ nsresult LoadExtensibleBundle(const char
 static
 nsresult GetBundleValue(nsIStringBundle * aBundle,
                         const char * aName,
                         const nsString& aProp,
                         char16_t ** aResult)
 {
   nsAutoString key;
 
-  key.AssignWithConversion(aName);
+  CopyASCIItoUTF16(aName, key);
   ToLowerCase(key); // we lowercase the main comparison key
   key.Append(aProp);
 
   return aBundle->GetStringFromName(NS_ConvertUTF16toUTF8(key).get(), aResult);
 }
 
 static
 nsresult GetBundleValue(nsIStringBundle * aBundle,