[jboss-cvs] JBossRemoting/src/main/org/jboss/remoting ...

Tom Elrod tom.elrod at jboss.com
Tue Dec 12 00:14:40 EST 2006


  User: telrod  
  Date: 06/12/12 00:14:40

  Modified:    src/main/org/jboss/remoting   ConnectionValidator.java
                        Client.java
  Log:
  JBREM-648 - fixe NPE for connection validator when client disconnects.
  
  Revision  Changes    Path
  1.14      +6 -2      JBossRemoting/src/main/org/jboss/remoting/ConnectionValidator.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: ConnectionValidator.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/ConnectionValidator.java,v
  retrieving revision 1.13
  retrieving revision 1.14
  diff -u -b -r1.13 -r1.14
  --- ConnectionValidator.java	11 Oct 2006 20:22:41 -0000	1.13
  +++ ConnectionValidator.java	12 Dec 2006 05:14:40 -0000	1.14
  @@ -66,9 +66,13 @@
         TimerUtil.schedule(this, pingPeriod);
      }
   
  -   private void stop()
  +   public void stop()
      {
         cancel();
  +      if (!listeners.isEmpty())
  +      {
  +         listeners.clear();
  +   }
      }
   
   
  
  
  
  1.61      +24 -18    JBossRemoting/src/main/org/jboss/remoting/Client.java
  
  (In the diff below, changes in quantity of whitespace are not shown.)
  
  Index: Client.java
  ===================================================================
  RCS file: /cvsroot/jboss/JBossRemoting/src/main/org/jboss/remoting/Client.java,v
  retrieving revision 1.60
  retrieving revision 1.61
  diff -u -b -r1.60 -r1.61
  --- Client.java	7 Dec 2006 20:44:09 -0000	1.60
  +++ Client.java	12 Dec 2006 05:14:40 -0000	1.61
  @@ -63,7 +63,7 @@
    *
    * @author <a href="mailto:jhaynie at vocalocity.net">Jeff Haynie</a>
    * @author <a href="mailto:telrod at e2technologies.net">Tom Elrod</a>
  - * @version $Revision: 1.60 $
  + * @version $Revision: 1.61 $
    */
   public class Client implements Externalizable
   {
  @@ -534,6 +534,12 @@
               enableLease = false;
            }
   
  +         if (connectionValidator!=null)
  +         {
  +            connectionValidator.stop();
  +            connectionValidator = null;
  +         }
  +
            /**
             * Need to remove myself from registry so will not keep
             * reference to me since I am of no use now. Will have to create
  
  
  



More information about the jboss-cvs-commits mailing list