You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by "Igor Vaynberg (JIRA)" <ji...@apache.org> on 2007/10/31 21:56:50 UTC

[jira] Resolved: (WICKET-1119) Strings.replaceAll giving StringIndexOutOfBoundsException

     [ https://issues.apache.org/jira/browse/WICKET-1119?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Igor Vaynberg resolved WICKET-1119.
-----------------------------------

       Resolution: Fixed
    Fix Version/s: 1.3.0-beta5
         Assignee: Igor Vaynberg

> Strings.replaceAll giving StringIndexOutOfBoundsException
> ---------------------------------------------------------
>
>                 Key: WICKET-1119
>                 URL: https://issues.apache.org/jira/browse/WICKET-1119
>             Project: Wicket
>          Issue Type: Bug
>          Components: wicket
>    Affects Versions: 1.3.0-beta4
>            Reporter: John Patterson
>            Assignee: Igor Vaynberg
>             Fix For: 1.3.0-beta5
>
>
> When replacing & characters it craps out.. this fixes it:
> Index: /Users/John/Development/wicket/trunk/jdk-1.4/wicket/src/main/java/org/apache/wicket/util/string/Strings.java
> ===================================================================
> --- /Users/John/Development/wicket/trunk/jdk-1.4/wicket/src/main/java/org/apache/wicket/util/string/Strings.java	(revision 589777)
> +++ /Users/John/Development/wicket/trunk/jdk-1.4/wicket/src/main/java/org/apache/wicket/util/string/Strings.java	(working copy)
> @@ -1327,7 +1327,7 @@
>  		}
>  		else
>  		{
> -			matchIndex = s.toString().indexOf(searchString);
> +			matchIndex = s.toString().indexOf(searchString, pos);
>  		}
>  		return matchIndex;
>  	}

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.