From 23f7d796c1ce2d2ea144ab61440f832724b03d47 Mon Sep 17 00:00:00 2001 From: "Olli.Pettay%helsinki.fi" Date: Wed, 28 Mar 2007 08:15:00 +0000 Subject: [PATCH] Bug 369249, r+sr=tor, a=dveditz git-svn-id: svn://10.0.0.236/branches/MOZILLA_1_8_BRANCH@222532 18797224-902f-48f8-a5cc-f745e15eee43 --- mozilla/content/svg/content/src/nsSVGLengthList.cpp | 4 ++-- mozilla/content/svg/content/src/nsSVGNumberList.cpp | 4 ++-- mozilla/content/svg/content/src/nsSVGPathSegList.cpp | 4 ++-- mozilla/content/svg/content/src/nsSVGPointList.cpp | 4 ++-- mozilla/content/svg/content/src/nsSVGTransformList.cpp | 4 ++-- 5 files changed, 10 insertions(+), 10 deletions(-) diff --git a/mozilla/content/svg/content/src/nsSVGLengthList.cpp b/mozilla/content/svg/content/src/nsSVGLengthList.cpp index e239c5a22cc..b7661b6af8b 100644 --- a/mozilla/content/svg/content/src/nsSVGLengthList.cpp +++ b/mozilla/content/svg/content/src/nsSVGLengthList.cpp @@ -225,7 +225,7 @@ NS_IMETHODIMP nsSVGLengthList::Initialize(nsIDOMSVGLength *newItem, /* nsIDOMSVGLength getItem (in unsigned long index); */ NS_IMETHODIMP nsSVGLengthList::GetItem(PRUint32 index, nsIDOMSVGLength **_retval) { - if ((PRInt32)index >= mLengths.Count()) { + if (index >= NS_STATIC_CAST(PRUint32, mLengths.Count())) { *_retval = nsnull; return NS_ERROR_DOM_INDEX_SIZE_ERR; } @@ -266,7 +266,7 @@ nsSVGLengthList::ReplaceItem(nsIDOMSVGLength *newItem, /* nsIDOMSVGLengthList removeItem (in unsigned long index); */ NS_IMETHODIMP nsSVGLengthList::RemoveItem(PRUint32 index, nsIDOMSVGLength **_retval) { - if ((PRInt32)index >= mLengths.Count()) { + if (index >= NS_STATIC_CAST(PRUint32, mLengths.Count())) { *_retval = nsnull; return NS_ERROR_DOM_INDEX_SIZE_ERR; } diff --git a/mozilla/content/svg/content/src/nsSVGNumberList.cpp b/mozilla/content/svg/content/src/nsSVGNumberList.cpp index 155f62ad3e6..7661cda582d 100644 --- a/mozilla/content/svg/content/src/nsSVGNumberList.cpp +++ b/mozilla/content/svg/content/src/nsSVGNumberList.cpp @@ -223,7 +223,7 @@ NS_IMETHODIMP nsSVGNumberList::Initialize(nsIDOMSVGNumber *newItem, /* nsIDOMSVGNumber getItem (in unsigned long index); */ NS_IMETHODIMP nsSVGNumberList::GetItem(PRUint32 index, nsIDOMSVGNumber **_retval) { - if ((PRInt32)index >= mNumbers.Count()) { + if (index >= NS_STATIC_CAST(PRUint32, mNumbers.Count())) { *_retval = nsnull; return NS_ERROR_DOM_INDEX_SIZE_ERR; } @@ -278,7 +278,7 @@ nsSVGNumberList::ReplaceItem(nsIDOMSVGNumber *newItem, /* nsIDOMSVGNumberList removeItem (in unsigned long index); */ NS_IMETHODIMP nsSVGNumberList::RemoveItem(PRUint32 index, nsIDOMSVGNumber **_retval) { - if ((PRInt32)index >= mNumbers.Count()) { + if (index >= NS_STATIC_CAST(PRUint32, mNumbers.Count())) { *_retval = nsnull; return NS_ERROR_DOM_INDEX_SIZE_ERR; } diff --git a/mozilla/content/svg/content/src/nsSVGPathSegList.cpp b/mozilla/content/svg/content/src/nsSVGPathSegList.cpp index a9e65a9a6ce..b34a4390b2c 100644 --- a/mozilla/content/svg/content/src/nsSVGPathSegList.cpp +++ b/mozilla/content/svg/content/src/nsSVGPathSegList.cpp @@ -223,7 +223,7 @@ NS_IMETHODIMP nsSVGPathSegList::Initialize(nsIDOMSVGPathSeg *newItem, /* nsIDOMSVGPathSeg getItem (in unsigned long index); */ NS_IMETHODIMP nsSVGPathSegList::GetItem(PRUint32 index, nsIDOMSVGPathSeg **_retval) { - if ((PRInt32)index >= mSegments.Count()) { + if (index >= NS_STATIC_CAST(PRUint32, mSegments.Count())) { *_retval = nsnull; return NS_ERROR_DOM_INDEX_SIZE_ERR; } @@ -262,7 +262,7 @@ NS_IMETHODIMP nsSVGPathSegList::ReplaceItem(nsIDOMSVGPathSeg *newItem, /* nsIDOMSVGPathSeg removeItem (in unsigned long index); */ NS_IMETHODIMP nsSVGPathSegList::RemoveItem(PRUint32 index, nsIDOMSVGPathSeg **_retval) { - if ((PRInt32)index >= mSegments.Count()) { + if (index >= NS_STATIC_CAST(PRUint32, mSegments.Count())) { *_retval = nsnull; return NS_ERROR_DOM_INDEX_SIZE_ERR; } diff --git a/mozilla/content/svg/content/src/nsSVGPointList.cpp b/mozilla/content/svg/content/src/nsSVGPointList.cpp index a1fdebe987a..9cea54b6c1e 100644 --- a/mozilla/content/svg/content/src/nsSVGPointList.cpp +++ b/mozilla/content/svg/content/src/nsSVGPointList.cpp @@ -277,7 +277,7 @@ NS_IMETHODIMP nsSVGPointList::Initialize(nsIDOMSVGPoint *newItem, /* nsIDOMSVGPoint getItem (in unsigned long index); */ NS_IMETHODIMP nsSVGPointList::GetItem(PRUint32 index, nsIDOMSVGPoint **_retval) { - if ((PRInt32)index >= mPoints.Count()) { + if (index >= NS_STATIC_CAST(PRUint32, mPoints.Count())) { *_retval = nsnull; return NS_ERROR_DOM_INDEX_SIZE_ERR; } @@ -316,7 +316,7 @@ NS_IMETHODIMP nsSVGPointList::ReplaceItem(nsIDOMSVGPoint *newItem, /* nsIDOMSVGPoint removeItem (in unsigned long index); */ NS_IMETHODIMP nsSVGPointList::RemoveItem(PRUint32 index, nsIDOMSVGPoint **_retval) { - if ((PRInt32)index >= mPoints.Count()) { + if (index >= NS_STATIC_CAST(PRUint32, mPoints.Count())) { *_retval = nsnull; return NS_ERROR_DOM_INDEX_SIZE_ERR; } diff --git a/mozilla/content/svg/content/src/nsSVGTransformList.cpp b/mozilla/content/svg/content/src/nsSVGTransformList.cpp index 3c2360194d6..832b4871cc9 100644 --- a/mozilla/content/svg/content/src/nsSVGTransformList.cpp +++ b/mozilla/content/svg/content/src/nsSVGTransformList.cpp @@ -378,7 +378,7 @@ NS_IMETHODIMP nsSVGTransformList::Initialize(nsIDOMSVGTransform *newItem, /* nsIDOMSVGTransform getItem (in unsigned long index); */ NS_IMETHODIMP nsSVGTransformList::GetItem(PRUint32 index, nsIDOMSVGTransform **_retval) { - if ((PRInt32)index >= mTransforms.Count()) { + if (index >= NS_STATIC_CAST(PRUint32, mTransforms.Count())) { *_retval = nsnull; return NS_ERROR_DOM_INDEX_SIZE_ERR; } @@ -456,7 +456,7 @@ NS_IMETHODIMP nsSVGTransformList::RemoveItem(PRUint32 index, nsIDOMSVGTransform { nsSVGValueAutoNotifier autonotifier(this); - if ((PRInt32)index >= mTransforms.Count()) { + if (index >= NS_STATIC_CAST(PRUint32, mTransforms.Count())) { *_retval = nsnull; return NS_ERROR_DOM_INDEX_SIZE_ERR; }