You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@activemq.apache.org by ta...@apache.org on 2010/09/14 17:27:02 UTC

svn commit: r996948 - /activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/wireformat/stomp/StompHelper.cpp

Author: tabish
Date: Tue Sep 14 15:27:02 2010
New Revision: 996948

URL: http://svn.apache.org/viewvc?rev=996948&view=rev
Log:
fix for: https://issues.apache.org/activemq/browse/AMQCPP-317

Modified:
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/wireformat/stomp/StompHelper.cpp

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/wireformat/stomp/StompHelper.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/wireformat/stomp/StompHelper.cpp?rev=996948&r1=996947&r2=996948&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/wireformat/stomp/StompHelper.cpp (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/activemq/wireformat/stomp/StompHelper.cpp Tue Sep 14 15:27:02 2010
@@ -265,9 +265,18 @@ Pointer<ConsumerId> StompHelper::convert
     }
 
     Pointer<ConsumerId> id( new ConsumerId() );
+
     StringTokenizer tokenizer( consumerId, ":" );
 
-    id->setConnectionId( tokenizer.nextToken() );
+    string connectionId;
+
+    connectionId += tokenizer.nextToken();
+    connectionId += ":";
+    connectionId += tokenizer.nextToken();
+    connectionId += ":";
+    connectionId += tokenizer.nextToken();
+
+    id->setConnectionId( connectionId );
 
     while( tokenizer.hasMoreTokens() ){
         string text = tokenizer.nextToken();
@@ -322,8 +331,13 @@ Pointer<TransactionId> StompHelper::conv
     Pointer<LocalTransactionId> id( new LocalTransactionId() );
     StringTokenizer tokenizer( transactionId, ":" );
 
+    string connectionIdStr;
+    connectionIdStr += tokenizer.nextToken();
+    connectionIdStr += ":";
+    connectionIdStr += tokenizer.nextToken();
+
     Pointer<ConnectionId> connectionId( new ConnectionId() );
-    connectionId->setValue( tokenizer.nextToken() );
+    connectionId->setValue( connectionIdStr );
     id->setConnectionId( connectionId );
 
     while( tokenizer.hasMoreTokens() ){