You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jetspeed-dev@portals.apache.org by "John Donald (JIRA)" <je...@portals.apache.org> on 2005/05/28 23:11:52 UTC

[jira] Created: (JS2-271) LayoutPortlet contains incompatible class cast

LayoutPortlet contains incompatible class cast
----------------------------------------------

         Key: JS2-271
         URL: http://issues.apache.org/jira/browse/JS2-271
     Project: Jetspeed 2
        Type: Bug
  Components: Layout  
    Versions: 2.0-M3    
    Reporter: John Donald


In line 280 the cast to RequestContext is not necessary, it leads to a class cast exception.
        JetspeedPowerTool tool = (JetspeedPowerTool) (RequestContext) request.getAttribute(PortalReservedParameters.JETSPEED_POWER_TOOL_REQ_ATTRIBUTE);
This does not happen in the default implementation as the request attribute is always null and created each time this code is executed. If the method were called more than once it would break.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org


[jira] Resolved: (JS2-271) LayoutPortlet contains incompatible class cast

Posted by "David Sean Taylor (JIRA)" <je...@portals.apache.org>.
     [ http://issues.apache.org/jira/browse/JS2-271?page=all ]
     
David Sean Taylor resolved JS2-271:
-----------------------------------

    Resolution: Fixed

Patch applied.
John, Please retest and close if it works for you...

> LayoutPortlet contains incompatible class cast
> ----------------------------------------------
>
>          Key: JS2-271
>          URL: http://issues.apache.org/jira/browse/JS2-271
>      Project: Jetspeed 2
>         Type: Bug
>   Components: Layout
>     Versions: 2.0-M3
>     Reporter: John Donald
>     Assignee: David Sean Taylor
>  Attachments: layoutportlet.patch
>
> In line 280 the cast to RequestContext is not necessary, it leads to a class cast exception.
>         JetspeedPowerTool tool = (JetspeedPowerTool) (RequestContext) request.getAttribute(PortalReservedParameters.JETSPEED_POWER_TOOL_REQ_ATTRIBUTE);
> This does not happen in the default implementation as the request attribute is always null and created each time this code is executed. If the method were called more than once it would break.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org


[jira] Updated: (JS2-271) LayoutPortlet contains incompatible class cast

Posted by "John Donald (JIRA)" <je...@portals.apache.org>.
     [ http://issues.apache.org/jira/browse/JS2-271?page=all ]

John Donald updated JS2-271:
----------------------------

    Attachment: layoutportlet.patch

This patch should correct the problem

> LayoutPortlet contains incompatible class cast
> ----------------------------------------------
>
>          Key: JS2-271
>          URL: http://issues.apache.org/jira/browse/JS2-271
>      Project: Jetspeed 2
>         Type: Bug
>   Components: Layout
>     Versions: 2.0-M3
>     Reporter: John Donald
>  Attachments: layoutportlet.patch
>
> In line 280 the cast to RequestContext is not necessary, it leads to a class cast exception.
>         JetspeedPowerTool tool = (JetspeedPowerTool) (RequestContext) request.getAttribute(PortalReservedParameters.JETSPEED_POWER_TOOL_REQ_ATTRIBUTE);
> This does not happen in the default implementation as the request attribute is always null and created each time this code is executed. If the method were called more than once it would break.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org


[jira] Assigned: (JS2-271) LayoutPortlet contains incompatible class cast

Posted by "David Sean Taylor (JIRA)" <je...@portals.apache.org>.
     [ http://issues.apache.org/jira/browse/JS2-271?page=all ]

David Sean Taylor reassigned JS2-271:
-------------------------------------

    Assign To: David Sean Taylor

> LayoutPortlet contains incompatible class cast
> ----------------------------------------------
>
>          Key: JS2-271
>          URL: http://issues.apache.org/jira/browse/JS2-271
>      Project: Jetspeed 2
>         Type: Bug
>   Components: Layout
>     Versions: 2.0-M3
>     Reporter: John Donald
>     Assignee: David Sean Taylor
>  Attachments: layoutportlet.patch
>
> In line 280 the cast to RequestContext is not necessary, it leads to a class cast exception.
>         JetspeedPowerTool tool = (JetspeedPowerTool) (RequestContext) request.getAttribute(PortalReservedParameters.JETSPEED_POWER_TOOL_REQ_ATTRIBUTE);
> This does not happen in the default implementation as the request attribute is always null and created each time this code is executed. If the method were called more than once it would break.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


---------------------------------------------------------------------
To unsubscribe, e-mail: jetspeed-dev-unsubscribe@portals.apache.org
For additional commands, e-mail: jetspeed-dev-help@portals.apache.org