mirror of https://github.com/apache/activemq.git
ensure that the check of whether or not the ConnectionInfo is sent to the broker - and the clientID created - is thread safe to fix AMQ-696
git-svn-id: https://svn.apache.org/repos/asf/incubator/activemq/trunk@398928 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
045353cde6
commit
b06de590e0
|
@ -1207,7 +1207,7 @@ public class ActiveMQConnection implements Connection, TopicConnection, QueueCon
|
||||||
*
|
*
|
||||||
* @throws JMSException
|
* @throws JMSException
|
||||||
*/
|
*/
|
||||||
protected void ensureConnectionInfoSent() throws JMSException {
|
protected synchronized void ensureConnectionInfoSent() throws JMSException {
|
||||||
// Can we skip sending the ConnectionInfo packet??
|
// Can we skip sending the ConnectionInfo packet??
|
||||||
if (isConnectionInfoSentToBroker || closed.get()) {
|
if (isConnectionInfoSentToBroker || closed.get()) {
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Reference in New Issue