[jboss-remoting-issues] [JBoss JIRA] Commented: (JBREM-1055) ConnectionValidator.run() should have a sanity test to prevent calls from application code

Ron Sigal (JIRA) jira-events at lists.jboss.org
Tue Nov 11 01:15:36 EST 2008


    [ https://jira.jboss.org/jira/browse/JBREM-1055?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12437805#action_12437805 ] 

Ron Sigal commented on JBREM-1055:
----------------------------------

Right, that's what I was thinking.  The known failure occurs because the user called ConnectionValidator.run() before the private method ConnectionValidator.start() gets called.  As a result, the clientInvoker and timer fields are null.  

> ConnectionValidator.run() should have a sanity test to prevent calls from application code
> ------------------------------------------------------------------------------------------
>
>                 Key: JBREM-1055
>                 URL: https://jira.jboss.org/jira/browse/JBREM-1055
>             Project: JBoss Remoting
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>    Affects Versions: 2.2.2.SP10, 2.5.0.SP1 (Flounder)
>            Reporter: Ron Sigal
>            Assignee: Ron Sigal
>            Priority: Minor
>             Fix For: 2.2.2.SP11, 2.5.0.SP2 (Flounder) 
>
>
> org.jboss.remoting.ConnectionValidator extends java.util.TimerTask which implements Runnable and has a public run() class.  run() needs to be public so it can be called by java.util.Timer, but it also exposes the method to application code, which can lead to a NullPointerException if run() is called directly.  There should be a log message to deter a direct call.

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

        



More information about the jboss-remoting-issues mailing list