Author: ritchiem
Date: Mon Feb  5 00:58:30 2007
New Revision: 503593

URL: http://svn.apache.org/viewvc?view=rev&rev=503593
Log:
Fixed bug in stop(). If a connection is opened not start()ed then closed a 
NullPointerException will be thrown as the Dispatcher has not been created. 

Modified:
    
incubator/qpid/trunk/qpid/java/client/src/main/java/org/apache/qpid/client/AMQSession.java

Modified: 
incubator/qpid/trunk/qpid/java/client/src/main/java/org/apache/qpid/client/AMQSession.java
URL: 
http://svn.apache.org/viewvc/incubator/qpid/trunk/qpid/java/client/src/main/java/org/apache/qpid/client/AMQSession.java?view=diff&rev=503593&r1=503592&r2=503593
==============================================================================
--- 
incubator/qpid/trunk/qpid/java/client/src/main/java/org/apache/qpid/client/AMQSession.java
 (original)
+++ 
incubator/qpid/trunk/qpid/java/client/src/main/java/org/apache/qpid/client/AMQSession.java
 Mon Feb  5 00:58:30 2007
@@ -1652,7 +1652,11 @@
     {
         //stop the server delivering messages to this session
         suspendChannel();
-        _dispatcher.setConnectionStopped(true);
+        
+        if (_dispatcher != null)
+        {
+            _dispatcher.setConnectionStopped(true);
+        }
     }
 
     /**


Reply via email to