Bug 645402 - Remove ToInteger() workarounds in mozilla-central. r=bz
authorCykesiopka <cykesiopka@hotmail.com>
Wed, 24 Apr 2013 08:36:09 -0400
changeset 140686 677a2e675dd9e6ffdc360cb9874acfbca73f00c0
parent 140685 4bba65656e46e524aa4eb9ff27a95b86af65a999
child 140687 a9fa331e7a0fe0483f8f9de15fc8fc851454c58d
push id2579
push userakeybl@mozilla.com
push dateMon, 24 Jun 2013 18:52:47 +0000
treeherdermozilla-beta@b69b7de8a05a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbz
bugs645402
milestone23.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 645402 - Remove ToInteger() workarounds in mozilla-central. r=bz
dom/indexedDB/OpenDatabaseHelper.cpp
dom/system/gonk/GonkGPSGeolocationProvider.cpp
editor/libeditor/html/nsHTMLCSSUtils.cpp
gfx/thebes/gfxSVGGlyphs.cpp
layout/base/nsCSSFrameConstructor.cpp
netwerk/protocol/ftp/nsFtpConnectionThread.cpp
--- a/dom/indexedDB/OpenDatabaseHelper.cpp
+++ b/dom/indexedDB/OpenDatabaseHelper.cpp
@@ -289,17 +289,17 @@ UpgradeSchemaFrom4To5(mozIStorageConnect
     rv = stmt->ExecuteStep(&hasResults);
     NS_ENSURE_SUCCESS(rv, rv);
     NS_ENSURE_TRUE(hasResults, NS_ERROR_FAILURE);
 
     nsString version;
     rv = stmt->GetString(1, version);
     NS_ENSURE_SUCCESS(rv, rv);
 
-    intVersion = version.ToInteger(&rv, 10);
+    intVersion = version.ToInteger(&rv);
     if (NS_FAILED(rv)) {
       intVersion = 0;
     }
 
     rv = stmt->GetString(0, name);
     NS_ENSURE_SUCCESS(rv, rv);
 
     rv = stmt->GetInt64(2, &dataVersion);
--- a/dom/system/gonk/GonkGPSGeolocationProvider.cpp
+++ b/dom/system/gonk/GonkGPSGeolocationProvider.cpp
@@ -450,23 +450,23 @@ GonkGPSGeolocationProvider::SetReference
     rilCtx->GetIccInfo(getter_AddRefs(iccInfo));
     if (iccInfo) {
       nsresult result;
       nsAutoString mcc, mnc;
 
       iccInfo->GetMcc(mcc);
       iccInfo->GetMnc(mnc);
 
-      location.u.cellID.mcc = mcc.ToInteger(&result, 10);
+      location.u.cellID.mcc = mcc.ToInteger(&result);
       if (result != NS_OK) {
         NS_WARNING("Cannot parse mcc to integer");
         location.u.cellID.mcc = 0;
       }
 
-      location.u.cellID.mnc = mnc.ToInteger(&result, 10);
+      location.u.cellID.mnc = mnc.ToInteger(&result);
       if (result != NS_OK) {
         NS_WARNING("Cannot parse mnc to integer");
         location.u.cellID.mnc = 0;
       }
     }
     nsCOMPtr<nsIDOMMozMobileConnectionInfo> voice;
     rilCtx->GetVoice(getter_AddRefs(voice));
     if (voice) {
--- a/editor/libeditor/html/nsHTMLCSSUtils.cpp
+++ b/editor/libeditor/html/nsHTMLCSSUtils.cpp
@@ -1105,17 +1105,17 @@ nsHTMLCSSUtils::IsCSSEquivalentToHTMLInl
         aIsSet = false;
       } else if (valueString.EqualsLiteral("bolder")) {
         aIsSet = true;
         valueString.AssignLiteral("bold");
       } else {
         int32_t weight = 0;
         nsresult errorCode;
         nsAutoString value(valueString);
-        weight = value.ToInteger(&errorCode, 10);
+        weight = value.ToInteger(&errorCode);
         if (400 < weight) {
           aIsSet = true;
           valueString.AssignLiteral("bold");
         } else {
           aIsSet = false;
           valueString.AssignLiteral("normal");
         }
       }
--- a/gfx/thebes/gfxSVGGlyphs.cpp
+++ b/gfx/thebes/gfxSVGGlyphs.cpp
@@ -397,17 +397,17 @@ void
 gfxSVGGlyphsDocument::InsertGlyphId(Element *aGlyphElement)
 {
     nsAutoString glyphIdStr;
     if (!aGlyphElement->GetAttr(kNameSpaceID_None, nsGkAtoms::glyphid, glyphIdStr)) {
         return;
     }
 
     nsresult rv;
-    uint32_t glyphId = glyphIdStr.ToInteger(&rv, kRadix10);
+    uint32_t glyphId = glyphIdStr.ToInteger(&rv);
 
     if (NS_FAILED(rv)) {
         return;
     }
 
     mGlyphIdMap.Put(glyphId, aGlyphElement);
 }
 
--- a/layout/base/nsCSSFrameConstructor.cpp
+++ b/layout/base/nsCSSFrameConstructor.cpp
@@ -1592,17 +1592,17 @@ nsCSSFrameConstructor::CreateGeneratedCo
       int32_t attrNameSpace = kNameSpaceID_None;
       nsAutoString contentString(data.mContent.mString);
       
       int32_t barIndex = contentString.FindChar('|'); // CSS namespace delimiter
       if (-1 != barIndex) {
         nsAutoString  nameSpaceVal;
         contentString.Left(nameSpaceVal, barIndex);
         nsresult error;
-        attrNameSpace = nameSpaceVal.ToInteger(&error, 10);
+        attrNameSpace = nameSpaceVal.ToInteger(&error);
         contentString.Cut(0, barIndex + 1);
         if (contentString.Length()) {
           if (mDocument->IsHTML() && aParentContent->IsHTML()) {
             ToLowerCase(contentString);
           }
           attrName = do_GetAtom(contentString);
         }
       }
--- a/netwerk/protocol/ftp/nsFtpConnectionThread.cpp
+++ b/netwerk/protocol/ftp/nsFtpConnectionThread.cpp
@@ -1032,27 +1032,27 @@ nsFtpState::R_mdtm() {
             mModTime = mResponseMsg;
 
             // Save lastModified time for downloaded files.
             nsAutoCString timeString;
             nsresult error;
             PRExplodedTime exTime;
 
             mResponseMsg.Mid(timeString, 0, 4);
-            exTime.tm_year  = timeString.ToInteger(&error, 10);
+            exTime.tm_year  = timeString.ToInteger(&error);
             mResponseMsg.Mid(timeString, 4, 2);
-            exTime.tm_month = timeString.ToInteger(&error, 10) - 1; //january = 0
+            exTime.tm_month = timeString.ToInteger(&error) - 1; //january = 0
             mResponseMsg.Mid(timeString, 6, 2);
-            exTime.tm_mday  = timeString.ToInteger(&error, 10);
+            exTime.tm_mday  = timeString.ToInteger(&error);
             mResponseMsg.Mid(timeString, 8, 2);
-            exTime.tm_hour  = timeString.ToInteger(&error, 10);
+            exTime.tm_hour  = timeString.ToInteger(&error);
             mResponseMsg.Mid(timeString, 10, 2);
-            exTime.tm_min   = timeString.ToInteger(&error, 10);
+            exTime.tm_min   = timeString.ToInteger(&error);
             mResponseMsg.Mid(timeString, 12, 2);
-            exTime.tm_sec   = timeString.ToInteger(&error, 10);
+            exTime.tm_sec   = timeString.ToInteger(&error);
             exTime.tm_usec  = 0;
 
             exTime.tm_params.tp_gmt_offset = 0;
             exTime.tm_params.tp_dst_offset = 0;
 
             PR_NormalizeTime(&exTime, PR_GMTParameters);
             exTime.tm_params = PR_LocalTimeParameters(&exTime);