activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r905816 - /activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/MessageConsumer.cs
Date Tue, 02 Feb 2010 22:15:52 GMT
Author: tabish
Date: Tue Feb  2 22:15:51 2010
New Revision: 905816

URL: http://svn.apache.org/viewvc?rev=905816&view=rev
Log:
* MessageConsumer.cs: 

http://issues.apache.org/activemq/browse/AMQNET-218

Only call ResetAbort if state has AbortRequested on.

Modified:
    activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/MessageConsumer.cs

Modified: activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/MessageConsumer.cs
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/MessageConsumer.cs?rev=905816&r1=905815&r2=905816&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/MessageConsumer.cs
(original)
+++ activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/MessageConsumer.cs
Tue Feb  2 22:15:51 2010
@@ -72,7 +72,7 @@
 			this.info = info;
 			this.redeliveryPolicy = this.session.Connection.RedeliveryPolicy;
 		}
-        
+
 		~MessageConsumer()
 		{
 			Dispose(false);
@@ -506,7 +506,10 @@
                                 // If aborted we stop the abort here and let normal processing
resume.
                                 // This allows the session to shutdown normally and ack all
messages
                                 // that have outstanding acks in this consumer.
-                                Thread.ResetAbort();
+                                if( (Thread.CurrentThread.ThreadState & ThreadState.AbortRequested)
== ThreadState.AbortRequested)
+                                {
+                                    Thread.ResetAbort();
+                                }
 							}
 						}
 						else



Mime
View raw message