Bug 113615
| Summary: | choosing the single-column layout causes an error | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [Retired] Red Hat Enterprise Portal Server | Reporter: | Vadim Nasardinov <vnasardinov> | ||||
| Component: | Admin ui | Assignee: | ccm-bugs-list | ||||
| Status: | CLOSED WONTFIX | QA Contact: | Jon Orris <jorris> | ||||
| Severity: | medium | Docs Contact: | |||||
| Priority: | medium | ||||||
| Version: | nightly | CC: | ccm-bugs-list | ||||
| Target Milestone: | --- | ||||||
| Target Release: | --- | ||||||
| Hardware: | All | ||||||
| OS: | Linux | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | Doc Type: | Bug Fix | |||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2005-08-03 18:41:36 UTC | Type: | --- | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Attachments: |
|
||||||
Created attachment 97041 [details]
screenshot
This screenshot shows which button to click in order to get the error,
in case my written instructins are unclear.
stale |
I am on the trunk at //portalserver/dev/...@39156, //core-platform/dev/...@39408 I set up a server instance running Core+CMS+PortalServer+Forum. I login as a system-wide admin and get redirected to my personal portal. I click on "Configure portal". Go to "Applications", create a Forum instance. Click on "Layout", add a tab. Add the "Recent forum postings" to the tab. Now, if I want to use the single-column layout (the first in the row of possible layouts under the "Layout" tab UI), I get the following exception. java.lang.StringIndexOutOfBoundsException: String index out of range: 1 at java.lang.String.charAt(String.java:511) at com.arsdigita.portalserver.ui.admin.PortletLayoutComponent.generateXMLHelper(PortletLayoutComponent.java:113) at com.arsdigita.portalserver.ui.admin.PortletLayoutComponent.generateXML(PortletLayoutComponent.java:314) at com.arsdigita.bebop.BoxPanel.generateXML(BoxPanel.java:119) at com.arsdigita.bebop.SimpleContainer.generateChildrenXML(SimpleContainer.java:243) at com.arsdigita.bebop.SimpleContainer.generateXML(SimpleContainer.java:260) at com.arsdigita.bebop.SplitWizard$WizardPaneSelector.generateXML(SplitWizard.java:238) at com.arsdigita.bebop.SplitPanel.generateXML(SplitPanel.java:239) at com.arsdigita.bebop.TabbedPane.generateXML(TabbedPane.java:444) at com.arsdigita.bebop.SimpleContainer.generateChildrenXML(SimpleContainer.java:243) at com.arsdigita.bebop.SimpleContainer.generateXML(SimpleContainer.java:260) at com.arsdigita.bebop.SimpleContainer.generateChildrenXML(SimpleContainer.java:243) at com.arsdigita.bebop.SimpleContainer.generateXML(SimpleContainer.java:260) at com.arsdigita.portalserver.CWPage$Panel.generateXML(CWPage.java:137) at com.arsdigita.bebop.Page.generateXML(Page.java:641) at com.arsdigita.portalserver.PortalPage.generateXML(PortalPage.java:250) at com.arsdigita.bebop.Page.buildDocument(Page.java:742) at com.arsdigita.bebop.page.PageDispatcher.dispatch(PageDispatcher.java:76) at com.arsdigita.portalserver.personal.PersonalPortalDispatcher.dispatch(PersonalPortalDispatcher.java:87) at com.arsdigita.web.LegacyAdapterServlet.doService(LegacyAdapterServlet.java:116) at com.arsdigita.web.BaseApplicationServlet$1.excurse(BaseApplicationServlet.java:111) at com.arsdigita.kernel.KernelExcursion.run(KernelExcursion.java:57) at com.arsdigita.web.BaseApplicationServlet.doService(BaseApplicationServlet.java:105) at com.arsdigita.web.BaseServlet$1.excurse(BaseServlet.java:176) at com.arsdigita.kernel.KernelExcursion.run(KernelExcursion.java:57) at com.arsdigita.web.BaseServlet.internalService(BaseServlet.java:147) at com.arsdigita.web.BaseServlet.doGet(BaseServlet.java:272) at javax.servlet.http.HttpServlet.service(HttpServlet.java:126) at javax.servlet.http.HttpServlet.service(HttpServlet.java:103) at com.caucho.server.http.FilterChainServlet.doFilter(FilterChainServlet.java:96) at com.caucho.server.http.Invocation.service(Invocation.java:312) Looking the source code makes me think it's an off-by-one error: $ p4 print \ //portalserver/dev/src/com/arsdigita/portalserver/ui/admin/PortletLayoutComponent.java#5 \ | grep -vE '^//portalserver' | cat -n | head -n 119 | tail -n 8 112 int cellNum = portlet.getCellNumber(); 113 if(layout.charAt(cellNum - 1) == 'n' || 114 layout.charAt(cellNum - 1) == 'w') 115 isLocked = true; 116 117 if(layout.length() == 2) { 118 if(cellNum == 1) { 119 if(layout.charAt(1) == 'n' ||