From 4889ea232130b9671333f06dd0a5b948c3ee5c49 Mon Sep 17 00:00:00 2001 From: "stewart@willster.(none)" <> Date: Wed, 24 Jan 2007 16:12:39 +1100 Subject: [PATCH] fix hpux build problem and some ndb connect errors being missed --- ndb/src/common/util/SocketClient.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ndb/src/common/util/SocketClient.cpp b/ndb/src/common/util/SocketClient.cpp index ec35fd3eb90..c2825901929 100644 --- a/ndb/src/common/util/SocketClient.cpp +++ b/ndb/src/common/util/SocketClient.cpp @@ -109,7 +109,7 @@ SocketClient::connect(const char *toaddress, unsigned short toport) struct timeval tval; int r; bool use_timeout; - socklen_t len; + SOCKOPT_OPTLEN_TYPE len; int flags; if (m_sockfd == NDB_INVALID_SOCKET) @@ -168,7 +168,7 @@ SocketClient::connect(const char *toaddress, unsigned short toport) if (FD_ISSET(m_sockfd, &rset) || FD_ISSET(m_sockfd, &wset)) { len= sizeof(r); - if (getsockopt(m_sockfd, SOL_SOCKET, SO_ERROR, &r, &len) < 0) + if (getsockopt(m_sockfd, SOL_SOCKET, SO_ERROR, &r, &len) < 0 || r) { // Solaris got an error... different than others NDB_CLOSE_SOCKET(m_sockfd);