зеркало из https://github.com/mozilla/pjs.git
Fix XPCOM_BREAK_ON_LOAD by restoring pre-string-branch Find() behavior when starting index is negative. Bug 243429, r+sr=darin
This commit is contained in:
Родитель
37d5442c36
Коммит
e94dce05c6
|
@ -905,7 +905,11 @@ Find_ComputeSearchRange( PRUint32 bigLen, PRUint32 littleLen, PRInt32& offset, P
|
|||
{
|
||||
// |count| specifies how many iterations to make from |offset|
|
||||
|
||||
if (offset < 0 || PRUint32(offset) > bigLen)
|
||||
if (offset < 0)
|
||||
{
|
||||
offset = 0;
|
||||
}
|
||||
else if (PRUint32(offset) > bigLen)
|
||||
{
|
||||
count = 0;
|
||||
return;
|
||||
|
|
Загрузка…
Ссылка в новой задаче