Return-Path: Delivered-To: apmail-activemq-commits-archive@www.apache.org Received: (qmail 39993 invoked from network); 4 Jul 2007 13:15:06 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 4 Jul 2007 13:15:06 -0000 Received: (qmail 18776 invoked by uid 500); 4 Jul 2007 13:15:09 -0000 Delivered-To: apmail-activemq-commits-archive@activemq.apache.org Received: (qmail 18725 invoked by uid 500); 4 Jul 2007 13:15:09 -0000 Mailing-List: contact commits-help@activemq.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@activemq.apache.org Delivered-To: mailing list commits@activemq.apache.org Received: (qmail 18716 invoked by uid 99); 4 Jul 2007 13:15:09 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 04 Jul 2007 06:15:09 -0700 X-ASF-Spam-Status: No, hits=-99.5 required=10.0 tests=ALL_TRUSTED,NO_REAL_NAME X-Spam-Check-By: apache.org Received: from [140.211.11.3] (HELO eris.apache.org) (140.211.11.3) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 04 Jul 2007 06:15:06 -0700 Received: by eris.apache.org (Postfix, from userid 65534) id B51291A981A; Wed, 4 Jul 2007 06:14:45 -0700 (PDT) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r553199 - /activemq/activemq-cpp/trunk/src/main/activemq/connector/openwire/OpenWireConnector.cpp Date: Wed, 04 Jul 2007 13:14:45 -0000 To: commits@activemq.apache.org From: tabish@apache.org X-Mailer: svnmailer-1.1.0 Message-Id: <20070704131445.B51291A981A@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: tabish Date: Wed Jul 4 06:14:44 2007 New Revision: 553199 URL: http://svn.apache.org/viewvc?view=rev&rev=553199 Log: minor code cleanup Modified: activemq/activemq-cpp/trunk/src/main/activemq/connector/openwire/OpenWireConnector.cpp Modified: activemq/activemq-cpp/trunk/src/main/activemq/connector/openwire/OpenWireConnector.cpp URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/main/activemq/connector/openwire/OpenWireConnector.cpp?view=diff&rev=553199&r1=553198&r2=553199 ============================================================================== --- activemq/activemq-cpp/trunk/src/main/activemq/connector/openwire/OpenWireConnector.cpp (original) +++ activemq/activemq-cpp/trunk/src/main/activemq/connector/openwire/OpenWireConnector.cpp Wed Jul 4 06:14:44 2007 @@ -302,16 +302,13 @@ } catch( ConnectorException& ex ){ try{ transport->close(); } catch( ... ){} - ex.setMark(__FILE__,__LINE__); throw ex; } catch( ... ) { try{ transport->close(); } catch( ... ){} - throw OpenWireConnectorException(__FILE__, __LINE__, "Caught unknown exception" ); } - } //////////////////////////////////////////////////////////////////////////////// @@ -762,7 +759,6 @@ throw OpenWireConnectorException( __FILE__, __LINE__, ex.what() ); - } catch( ... ) { delete producer; delete producerInfo; @@ -1036,7 +1032,6 @@ ex.setMark(__FILE__,__LINE__); throw ex; } catch( ... ) { - try{ transport->close(); } catch( ... ){} throw OpenWireConnectorException( __FILE__, __LINE__, @@ -1081,7 +1076,6 @@ ex.setMark(__FILE__,__LINE__); throw ex; } catch( ... ) { - try{ transport->close(); } catch( ... ){} throw OpenWireConnectorException( __FILE__, __LINE__, @@ -1119,7 +1113,6 @@ ex.setMark(__FILE__,__LINE__); throw ex; } catch( ... ) { - try{ transport->close(); } catch( ... ){} throw OpenWireConnectorException( __FILE__, __LINE__, @@ -1157,7 +1150,6 @@ ex.setMark(__FILE__,__LINE__); throw ex; } catch( ... ) { - try{ transport->close(); } catch( ... ){} throw OpenWireConnectorException( __FILE__, __LINE__, @@ -1171,8 +1163,7 @@ TransactionInfo* transaction AMQCPP_UNUSED ) throw ( ConnectorException ) { - try - { + try { return new commands::ActiveMQMessage(); } AMQ_CATCH_RETHROW( ConnectorException ) @@ -1185,8 +1176,7 @@ TransactionInfo* transaction AMQCPP_UNUSED ) throw ( ConnectorException ) { - try - { + try { return new commands::ActiveMQBytesMessage(); } AMQ_CATCH_RETHROW( ConnectorException ) @@ -1199,8 +1189,7 @@ TransactionInfo* transaction AMQCPP_UNUSED ) throw ( ConnectorException ) { - try - { + try { return new commands::ActiveMQTextMessage(); } AMQ_CATCH_RETHROW( ConnectorException ) @@ -1213,8 +1202,7 @@ TransactionInfo* transaction AMQCPP_UNUSED ) throw ( ConnectorException, UnsupportedOperationException ) { - try - { + try { return new commands::ActiveMQMapMessage(); } AMQ_CATCH_RETHROW( ConnectorException ) @@ -1227,8 +1215,8 @@ { commands::RemoveSubscriptionInfo* rsi = NULL; - try - { + try { + enforceConnected(); rsi = new commands::RemoveSubscriptionInfo(); @@ -1261,8 +1249,8 @@ void OpenWireConnector::closeResource( ConnectorResource* resource ) throw ( ConnectorException ) { - try - { + try { + if( resource == NULL ) { return; } @@ -1430,8 +1418,7 @@ void OpenWireConnector::oneway( Command* command ) throw ( ConnectorException ) { - try - { + try { transport->oneway(command); } AMQ_CATCH_EXCEPTION_CONVERT( CommandIOException, OpenWireConnectorException )