diff --git a/mozilla/base/src/nsString.cpp b/mozilla/base/src/nsString.cpp index 1c5154abd00..0191c9d1b50 100644 --- a/mozilla/base/src/nsString.cpp +++ b/mozilla/base/src/nsString.cpp @@ -588,6 +588,9 @@ PRInt32 nsString::ToInteger(PRInt32* aErrorCode,PRInt32 aRadix) const { result=-result; break; } + else if('+'==theChar) { + break; + } else{ *aErrorCode=NS_ERROR_ILLEGAL_VALUE; result=0; diff --git a/mozilla/string/obsolete/nsString.cpp b/mozilla/string/obsolete/nsString.cpp index 1c5154abd00..0191c9d1b50 100644 --- a/mozilla/string/obsolete/nsString.cpp +++ b/mozilla/string/obsolete/nsString.cpp @@ -588,6 +588,9 @@ PRInt32 nsString::ToInteger(PRInt32* aErrorCode,PRInt32 aRadix) const { result=-result; break; } + else if('+'==theChar) { + break; + } else{ *aErrorCode=NS_ERROR_ILLEGAL_VALUE; result=0; diff --git a/mozilla/xpcom/ds/nsString.cpp b/mozilla/xpcom/ds/nsString.cpp index 1c5154abd00..0191c9d1b50 100644 --- a/mozilla/xpcom/ds/nsString.cpp +++ b/mozilla/xpcom/ds/nsString.cpp @@ -588,6 +588,9 @@ PRInt32 nsString::ToInteger(PRInt32* aErrorCode,PRInt32 aRadix) const { result=-result; break; } + else if('+'==theChar) { + break; + } else{ *aErrorCode=NS_ERROR_ILLEGAL_VALUE; result=0; diff --git a/mozilla/xpcom/string/obsolete/nsString.cpp b/mozilla/xpcom/string/obsolete/nsString.cpp index 1c5154abd00..0191c9d1b50 100644 --- a/mozilla/xpcom/string/obsolete/nsString.cpp +++ b/mozilla/xpcom/string/obsolete/nsString.cpp @@ -588,6 +588,9 @@ PRInt32 nsString::ToInteger(PRInt32* aErrorCode,PRInt32 aRadix) const { result=-result; break; } + else if('+'==theChar) { + break; + } else{ *aErrorCode=NS_ERROR_ILLEGAL_VALUE; result=0;