Create new v1.6.1 release tag
diff --git a/package.ps1 b/package.ps1
index 1b79f83..aa8bb30 100644
--- a/package.ps1
+++ b/package.ps1
@@ -14,7 +14,7 @@
 # limitations under the License.

 

 $pkgname = "Apache.NMS.ActiveMQ"

-$pkgver = "1.6.1"

+$pkgver = "1.6.1

 $configurations = "release", "debug"

 $frameworks = "mono-2.0", "net-2.0", "net-3.5", "net-4.0"

 

diff --git a/src/main/csharp/NetTxTransactionContext.cs b/src/main/csharp/NetTxTransactionContext.cs
index e5869a2..9146192 100644
--- a/src/main/csharp/NetTxTransactionContext.cs
+++ b/src/main/csharp/NetTxTransactionContext.cs
@@ -196,7 +196,7 @@
                     info.Type = (int)TransactionType.End;
 
                     this.connection.CheckConnected();
-                    this.connection.SyncRequest(info);
+                    this.connection.SyncRequest((TransactionInfo) info.Clone());
 
                     // Prepare the Transaction for commit.
                     info.Type = (int)TransactionType.Prepare;
@@ -214,7 +214,7 @@
 
                         // if server responds that nothing needs to be done, then reply done.
                         // otherwise the DTC will call Commit or Rollback but another transaction
-                        // can already be in progress and this one would be commited or rolled back 
+                        // can already be in progress and this one would be commited or rolled back
                         // immediately.
                         preparingEnlistment.Done();
 
@@ -495,7 +495,7 @@
         /// Should be called from NetTxSession when created to check if any TX
         /// data is stored for recovery and whether the Broker has matching info
         /// stored.  If an Transaction is found that belongs to this client and is
-        /// still alive on the Broker it will be recovered, otherwise the stored 
+        /// still alive on the Broker it will be recovered, otherwise the stored
         /// data should be cleared.
         /// </summary>
         public void InitializeDtcTxContext()
@@ -515,7 +515,7 @@
             if (recoverables.Length == 0)
             {
                 Tracer.Debug("Did not detect any recoverable transactions at Broker.");
-                // Broker has no recoverable data so nothing to do here, delete the 
+                // Broker has no recoverable data so nothing to do here, delete the
                 // old recovery log as its stale.
                 RecoveryLogger.Purge();
                 return;
diff --git a/src/main/csharp/State/ConnectionStateTracker.cs b/src/main/csharp/State/ConnectionStateTracker.cs
index 65814ea..c4069ed 100644
--- a/src/main/csharp/State/ConnectionStateTracker.cs
+++ b/src/main/csharp/State/ConnectionStateTracker.cs
@@ -43,7 +43,6 @@
         private bool isRestoreTransaction = true;
         private bool isTrackMessages = true;
         private int maxCacheSize = 256;
-        private int currentCacheSize;
         private readonly LRUCache<Object, Command> messageCache = new LRUCache<Object, Command>(256);
 
         private class RemoveTransactionAction : ResponseHandler
@@ -90,21 +89,6 @@
 
         public void TrackBack(Command command)
         {
-            if (command != null)
-            {
-                if (TrackMessages && command.IsMessage)
-                {
-                    Message message = (Message) command;
-                    if(message.TransactionId == null)
-                    {
-                        currentCacheSize = currentCacheSize + 1;
-                    }
-                }
-                else if (command.IsMessagePull)
-                {
-                    currentCacheSize = currentCacheSize + 1;
-                }
-            }
         }
 
         public void DoRestore(ITransport transport)