http://nagoya.apache.org/bugzilla/show_bug.cgi?id=2684 *** shadow/2684 Wed Jul 18 21:04:08 2001 --- shadow/2684.tmp.18936 Wed Jul 18 21:04:08 2001 *************** *** 0 **** --- 1,27 ---- + +============================================================================+ + | StringIndexOutOfBoundsException is trailing illegal quote | + +----------------------------------------------------------------------------+ + | Bug #: 2684 Product: XalanJ2 | + | Status: NEW Version: 2.1.0 | + | Resolution: Platform: PC | + | Severity: Minor OS/Version: Windows NT/2K | + | Priority: Other Component: org.apache.xpath | + +----------------------------------------------------------------------------+ + | Assigned To: [EMAIL PROTECTED] | + | Reported By: [EMAIL PROTECTED] | + | CC list: Cc: | + +----------------------------------------------------------------------------+ + | URL: | + +============================================================================+ + | DESCRIPTION | + <xsl:with-param name="label" select="@label'"/> + + The above is invalid (with the unopened trailing quote) but Xalan doesn't + handle it gracefully. It results in a StringIndexOutOfBounds exception at line + 235 of org.apache.xpath.compiler.Lexer. + + for (i++; (i < nChars) && ((c = pat.charAt(i)) != '\''); i++); + + if (c == '\'') + { + addToTokenQueue(pat.substring(startSubstring, i + 1));
