Uploaded image for project: 'Seam 2'
  1. Seam 2
  2. JBSEAM-1897

consecutive s:link elements causes an ArrayIndexOutOfBoundsException

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Cannot Reproduce
    • Affects Version/s: 2.0.0.CR1, 2.0.0.CR3, 2.0.1.CR1
    • Fix Version/s: None
    • Component/s: EL, JSF Integration
    • Labels:
      None
    • Environment:

      JBoss 4.2.1 JBoss Seam BETA1 and up

    • Workaround:
      Workaround Exists
    • Workaround Description:
      Hide

      Use <span></span> to seperate the <s:link></s:link> tags

      Show
      Use <span></span> to seperate the <s:link></s:link> tags

      Description

      If you have something like

      <p id="breadcrumb"><s:link view="/home.xhtml">Home</s:link> \ <s:link view="/contact.xhtml">Contact</s:link> \ <s:link view="/suggestion.xhtml" styleClass="current">Make a Suggestion</s:link></p>

      you get an ArrayIndexOutOfBoundsException but if you put any html (such as a span tag) between the s:ink tags it works fine. For example replace the above with this

      <p id="breadcrumb"><s:link view="/home.xhtml">Home</s:link><span> \ </span><s:link view="/contact.xhtml">Contact</s:link><span> \ </span><s:link view="/suggestion.xhtml" styleClass="current">Make a Suggestion</s:link></p>

      and your all good.

      java.lang.ArrayIndexOutOfBoundsException: 2
      at com.sun.facelets.el.ELText.parse(ELText.java:319)
      at com.sun.facelets.el.ELText.parse(ELText.java:282)
      at com.sun.facelets.compiler.TextUnit.flushTextBuffer(TextUnit.java:98)
      at com.sun.facelets.compiler.TextUnit.flushBufferToConfig(TextUnit.java:216)
      at com.sun.facelets.compiler.TextUnit.addChild(TextUnit.java:207)
      at com.sun.facelets.compiler.CompilationManager.startUnit(CompilationManager.java:297)
      at com.sun.facelets.compiler.CompilationManager.pushTag(CompilationManager.java:191)
      at com.sun.facelets.compiler.SAXCompiler$CompilationHandler.startElement(SAXCompiler.java:194)
      at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source)
      at org.apache.xerces.impl.dtd.XMLDTDValidator.startElement(Unknown Source)
      at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
      at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
      at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
      at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
      at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
      at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
      at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
      at org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source)
      at javax.xml.parsers.SAXParser.parse(SAXParser.java:375)
      at javax.xml.parsers.SAXParser.parse(SAXParser.java:176)
      at com.sun.facelets.compiler.SAXCompiler.doCompile(SAXCompiler.java:232)
      at com.sun.facelets.compiler.Compiler.compile(Compiler.java:105)
      at com.sun.facelets.impl.DefaultFaceletFactory.createFacelet(DefaultFaceletFactory.java:197)
      at com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:144)
      at com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:95)
      at com.sun.facelets.FaceletViewHandler.buildView(FaceletViewHandler.java:502)
      at com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:552)
      at org.ajax4jsf.framework.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:108)
      at org.ajax4jsf.framework.ajax.AjaxViewHandler.renderView(AjaxViewHandler.java:233)
      at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:106)
      at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:251)
      at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:144)
      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:245)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:83)
      at org.jboss.seam.debug.hot.HotDeployFilter.doFilter(HotDeployFilter.java:68)
      at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
      at org.jboss.seam.web.MultipartFilter.doFilter(MultipartFilter.java:85)
      at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
      at org.jboss.seam.web.ExceptionFilter.doFilter(ExceptionFilter.java:64)
      at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
      at org.jboss.seam.web.RedirectFilter.doFilter(RedirectFilter.java:44)
      at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
      at org.ajax4jsf.framework.ajax.xmlfilter.BaseXMLFilter.doXmlFilter(BaseXMLFilter.java:127)
      at org.ajax4jsf.framework.ajax.xmlfilter.BaseFilter.doFilter(BaseFilter.java:277)
      at org.jboss.seam.web.Ajax4jsfFilter.doFilter(Ajax4jsfFilter.java:60)
      at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
      at org.jboss.seam.web.LoggingFilter.doFilter(LoggingFilter.java:58)
      at org.jboss.seam.servlet.SeamFilter$FilterChainImpl.doFilter(SeamFilter.java:69)
      at org.jboss.seam.servlet.SeamFilter.doFilter(SeamFilter.java:150)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      at org.tuckey.web.filters.urlrewrite.RuleChain.handleRewrite(RuleChain.java:164)
      at org.tuckey.web.filters.urlrewrite.RuleChain.doRules(RuleChain.java:141)
      at org.tuckey.web.filters.urlrewrite.UrlRewriter.processRequest(UrlRewriter.java:90)
      at org.tuckey.web.filters.urlrewrite.UrlRewriteFilter.doFilter(UrlRewriteFilter.java:395)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
      at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:179)
      at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:525)
      at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:104)
      at org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:241)
      at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
      at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:580)
      at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:447)
      at java.lang.Thread.run(Thread.java:613)

        Gliffy Diagrams

          Attachments

            Activity

              People

              • Assignee:
                pmuir Pete Muir
                Reporter:
                apwalker Aaron Walker
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: