activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r947038 - in /activemq/activemq-cpp/trunk/activemq-cpp/src: main/decaf/internal/net/Network.cpp test/decaf/net/SocketTest.cpp
Date Fri, 21 May 2010 15:23:17 GMT
Author: tabish
Date: Fri May 21 15:23:15 2010
New Revision: 947038

URL: http://svn.apache.org/viewvc?rev=947038&view=rev
Log:
https://issues.apache.org/activemq/browse/AMQCPP-140

Fix for windows builds.

Modified:
    activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/net/Network.cpp
    activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/net/SocketTest.cpp

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/net/Network.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/net/Network.cpp?rev=947038&r1=947037&r2=947038&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/net/Network.cpp (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/main/decaf/internal/net/Network.cpp Fri May
21 15:23:15 2010
@@ -22,6 +22,8 @@
 #include <decaf/util/concurrent/Mutex.h>
 #include <decaf/internal/util/ResourceLifecycleManager.h>
 
+#include <apr_signal.h>
+
 using namespace decaf;
 using namespace decaf::internal;
 using namespace decaf::internal::net;
@@ -87,6 +89,12 @@ Mutex* Network::getRuntimeLock() {
 ////////////////////////////////////////////////////////////////////////////////
 void Network::initializeNetworking() {
 
+#ifndef WIN32
+    // Remove the SIGPIPE so that the application isn't aborted if a connected
+    // socket breaks during a read or write.
+    apr_signal_block( SIGPIPE );
+#endif
+
     // Create the Network Runtime
     Network::networkRuntime = new Network();
 }

Modified: activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/net/SocketTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/net/SocketTest.cpp?rev=947038&r1=947037&r2=947038&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/net/SocketTest.cpp (original)
+++ activemq/activemq-cpp/trunk/activemq-cpp/src/test/decaf/net/SocketTest.cpp Fri May 21
15:23:15 2010
@@ -348,9 +348,6 @@ namespace {
 ////////////////////////////////////////////////////////////////////////////////
 void SocketTest::testGetOutputStream() {
 
-    // Remove the SIGPIPE so that the CPPUNIT tests don't quit when sockets are broken.
-    apr_signal_block( SIGPIPE );
-
     {
         // Simple fetch test
         ServerSocket server(0);



Mime
View raw message