Author: rgodfrey
Date: Thu Apr 21 08:01:34 2016
New Revision: 1740248

URL: http://svn.apache.org/viewvc?rev=1740248&view=rev
Log:
QPID-7202 : Fix NPE when writing heartbeat frames

Modified:
    
qpid/java/trunk/broker-plugins/amqp-1-0-protocol/src/main/java/org/apache/qpid/server/protocol/v1_0/codec/FrameWriter.java

Modified: 
qpid/java/trunk/broker-plugins/amqp-1-0-protocol/src/main/java/org/apache/qpid/server/protocol/v1_0/codec/FrameWriter.java
URL: 
http://svn.apache.org/viewvc/qpid/java/trunk/broker-plugins/amqp-1-0-protocol/src/main/java/org/apache/qpid/server/protocol/v1_0/codec/FrameWriter.java?rev=1740248&r1=1740247&r2=1740248&view=diff
==============================================================================
--- 
qpid/java/trunk/broker-plugins/amqp-1-0-protocol/src/main/java/org/apache/qpid/server/protocol/v1_0/codec/FrameWriter.java
 (original)
+++ 
qpid/java/trunk/broker-plugins/amqp-1-0-protocol/src/main/java/org/apache/qpid/server/protocol/v1_0/codec/FrameWriter.java
 Thu Apr 21 08:01:34 2016
@@ -63,7 +63,10 @@ public class FrameWriter
         body.put((byte)2); // DOFF
         body.put(frame.getFrameType()); // AMQP Frame Type
         body.putShort(frame.getChannel());
-        typeWriter.writeToBuffer(body);
+        if(typeWriter != null)
+        {
+            typeWriter.writeToBuffer(body);
+        }
         body.flip();
 
         _sender.send(body);



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to