activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jstrac...@apache.org
Subject svn commit: r508374 - /activemq/activemq-dotnet/trunk/src/main/csharp/ActiveMQ/Transport/ResponseCorrelator.cs
Date Fri, 16 Feb 2007 11:50:56 GMT
Author: jstrachan
Date: Fri Feb 16 03:50:55 2007
New Revision: 508374

URL: http://svn.apache.org/viewvc?view=rev&rev=508374
Log:
Added better error detection for nulls

Modified:
    activemq/activemq-dotnet/trunk/src/main/csharp/ActiveMQ/Transport/ResponseCorrelator.cs

Modified: activemq/activemq-dotnet/trunk/src/main/csharp/ActiveMQ/Transport/ResponseCorrelator.cs
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/trunk/src/main/csharp/ActiveMQ/Transport/ResponseCorrelator.cs?view=diff&rev=508374&r1=508373&r2=508374
==============================================================================
--- activemq/activemq-dotnet/trunk/src/main/csharp/ActiveMQ/Transport/ResponseCorrelator.cs
(original)
+++ activemq/activemq-dotnet/trunk/src/main/csharp/ActiveMQ/Transport/ResponseCorrelator.cs
Fri Feb 16 03:50:55 2007
@@ -65,11 +65,16 @@
         {
             FutureResponse future = AsyncRequest(command);
             Response response = future.Response;
-            if (response is ExceptionResponse)
+            if (response != null && response is ExceptionResponse)
             {
                 ExceptionResponse er = (ExceptionResponse) response;
                 BrokerError brokerError = er.Exception;
-                throw new BrokerException(brokerError);
+				if (brokerError == null) {
+	                throw new BrokerException();
+				}
+				else {
+	                throw new BrokerException(brokerError);
+				}
             }
             return response;
         }



Mime
View raw message