diff --git a/mozilla/string/obsolete/nsStr.cpp b/mozilla/string/obsolete/nsStr.cpp index 528d321c2ee..28e641f585c 100644 --- a/mozilla/string/obsolete/nsStr.cpp +++ b/mozilla/string/obsolete/nsStr.cpp @@ -450,21 +450,11 @@ PRInt32 nsStr::FindSubstr(const nsStr& aDest,const nsStr& aTarget, PRBool aIgnor PRBool matches=PR_TRUE; while((++theSubIndex0) { - if(theFirstTargetChar==theChar){ - PRUnichar theDestJumpChar=GetCharAt(aDest,index+theTargetMax); - if(theDestJumpChar==theLastTargetChar) { - theNewStartPos=index; //this lets us jump ahead during our search where possible. - }//if - }//if - }//if PRUnichar theTargetChar=GetCharAt(aTarget,theSubIndex); matches=PRBool(theChar==theTargetChar); } - if(matches) + if(matches) { return index; - if(-10) { - if(theFirstTargetChar==theChar){ - PRUnichar theDestJumpChar=GetCharAt(aDest,index+theTargetMax); - if(theDestJumpChar==theLastTargetChar) { - theNewStartPos=index; //this lets us jump ahead during our search where possible. - }//if - }//if - }//if PRUnichar theTargetChar=GetCharAt(aTarget,theSubIndex); matches=PRBool(theChar==theTargetChar); } //while } //if - if(matches) + if(matches) { return index; - if(-10) { - if(theFirstTargetChar==theChar){ - PRUnichar theDestJumpChar=GetCharAt(aDest,index+theTargetMax); - if(theDestJumpChar==theLastTargetChar) { - theNewStartPos=index; //this lets us jump ahead during our search where possible. - }//if - }//if - }//if PRUnichar theTargetChar=GetCharAt(aTarget,theSubIndex); matches=PRBool(theChar==theTargetChar); } - if(matches) + if(matches) { return index; - if(-10) { - if(theFirstTargetChar==theChar){ - PRUnichar theDestJumpChar=GetCharAt(aDest,index+theTargetMax); - if(theDestJumpChar==theLastTargetChar) { - theNewStartPos=index; //this lets us jump ahead during our search where possible. - }//if - }//if - }//if PRUnichar theTargetChar=GetCharAt(aTarget,theSubIndex); matches=PRBool(theChar==theTargetChar); } //while } //if - if(matches) + if(matches) { return index; - if(-10) { - if(theFirstTargetChar==theChar){ - PRUnichar theDestJumpChar=GetCharAt(aDest,index+theTargetMax); - if(theDestJumpChar==theLastTargetChar) { - theNewStartPos=index; //this lets us jump ahead during our search where possible. - }//if - }//if - }//if PRUnichar theTargetChar=GetCharAt(aTarget,theSubIndex); matches=PRBool(theChar==theTargetChar); } - if(matches) + if(matches) { return index; - if(-10) { - if(theFirstTargetChar==theChar){ - PRUnichar theDestJumpChar=GetCharAt(aDest,index+theTargetMax); - if(theDestJumpChar==theLastTargetChar) { - theNewStartPos=index; //this lets us jump ahead during our search where possible. - }//if - }//if - }//if PRUnichar theTargetChar=GetCharAt(aTarget,theSubIndex); matches=PRBool(theChar==theTargetChar); } //while } //if - if(matches) + if(matches) { return index; - if(-1