Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/main/java/com/rabbitmq/client/impl/AMQConnection.java
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,10 @@ public void start()
// initiator) is to wait for a connection.start method to
// arrive.
_channel0.enqueueRpc(connStartBlocker);
// Must happen before the header is sent: sending it can make the broker reply
// immediately, and the I/O thread that reads that reply needs the connection
// reference to already be in place, or it hits a null reference.
this._frameHandler.initialize(this);
try {
// The following two lines are akin to AMQChannel's
// transmit() method for this pseudo-RPC.
Expand All @@ -331,8 +335,6 @@ public void start()
throw ioe;
}

this._frameHandler.initialize(this);

AMQP.Connection.Start connStart;
AMQP.Connection.Tune connTune = null;
try {
Expand Down
Loading