Bug 598316 - Fix a comparison between signed and unsigned integers in nsHTMLFieldSetElement::InsertChildAt; r=volkmar a=jst
☠☠ backed out by defdd7460560 ☠ ☠
authorMs2ger <ms2ger@gmail.com>
Fri, 15 Oct 2010 17:23:06 +0200
changeset 55870 ce62f87104e1863e89c4a7174ff4cdc78f1f41eb
parent 55869 f6aed030551c9be84e4883f49c7bee7449ad2a9a
child 55871 09adce374ccd1e46cc83e92250693d99174f0b10
child 55880 defdd7460560ab60ac5e054364e3ff302b1e1fd2
push id1
push userroot
push dateTue, 26 Apr 2011 22:38:44 +0000
treeherdermozilla-beta@bfdb6e623a36 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersvolkmar, jst
bugs598316
milestone2.0b8pre
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 598316 - Fix a comparison between signed and unsigned integers in nsHTMLFieldSetElement::InsertChildAt; r=volkmar a=jst
content/html/content/src/nsHTMLFieldSetElement.cpp
--- a/content/html/content/src/nsHTMLFieldSetElement.cpp
+++ b/content/html/content/src/nsHTMLFieldSetElement.cpp
@@ -188,17 +188,17 @@ nsHTMLFieldSetElement::InsertChildAt(nsI
 
   if (aChild->IsHTML(nsGkAtoms::legend)) {
     if (!mFirstLegend) {
       mFirstLegend = aChild;
       // We do not want to notify the first time mFirstElement is set.
     } else {
       // If mFirstLegend is before aIndex, we do not change it.
       // Otherwise, mFirstLegend is now aChild.
-      if (aIndex <= IndexOf(mFirstLegend)) {
+      if (PRInt32(aIndex) <= IndexOf(mFirstLegend)) {
         mFirstLegend = aChild;
         firstLegendHasChanged = true;
       }
     }
   }
 
   nsresult rv = nsGenericHTMLFormElement::InsertChildAt(aChild, aIndex, aNotify);
   NS_ENSURE_SUCCESS(rv, rv);