summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMartin Sustrik <sustrik@250bpm.com>2010-02-10 11:04:28 +0100
committerMartin Sustrik <sustrik@250bpm.com>2010-02-10 11:04:28 +0100
commit2d44bf3644c8e12aa86c48e9da4df19bfa9ea703 (patch)
tree2081a96cb410ab22301c603a6e57020b60b46082
parent8c25bab31d63bf5e2c4eec6d9084cf7d1c1e5dd3 (diff)
ZMQII-69: Make 0MQ build on HP-UX
-rw-r--r--src/fd_signaler.cpp4
-rw-r--r--src/tcp_connecter.cpp6
2 files changed, 7 insertions, 3 deletions
diff --git a/src/fd_signaler.cpp b/src/fd_signaler.cpp
index 9ab307e..f1ec6af 100644
--- a/src/fd_signaler.cpp
+++ b/src/fd_signaler.cpp
@@ -249,10 +249,10 @@ void zmq::fd_signaler_t::signal (int signal_)
uint64_t zmq::fd_signaler_t::poll ()
{
// Set the reader to blocking mode.
- int flags = fcntl (fd, F_GETFL, 0);
+ int flags = fcntl (r, F_GETFL, 0);
if (flags == -1)
flags = 0;
- int rc = fcntl (fd, F_SETFL, flags & ~O_NONBLOCK);
+ int rc = fcntl (r, F_SETFL, flags & ~O_NONBLOCK);
errno_assert (rc != -1);
// Poll for events.
diff --git a/src/tcp_connecter.cpp b/src/tcp_connecter.cpp
index 4df4fae..06214e2 100644
--- a/src/tcp_connecter.cpp
+++ b/src/tcp_connecter.cpp
@@ -268,7 +268,11 @@ zmq::fd_t zmq::tcp_connecter_t::connect ()
// Following code should handle both Berkeley-derived socket
// implementations and Solaris.
int err = 0;
- socklen_t len = sizeof err;
+#if defined ZMQ_HAVE_HPUX
+ int len = sizeof (err);
+#else
+ socklen_t len = sizeof (err);
+#endif
int rc = getsockopt (s, SOL_SOCKET, SO_ERROR, (char*) &err, &len);
if (rc == -1)
err = errno;