summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRobert Griebl <rgriebl@trolltech.com>2009-07-15 10:25:50 (GMT)
committerRobert Griebl <rgriebl@trolltech.com>2009-07-15 10:27:24 (GMT)
commit28d0930593c6c04a7ef538353f8bee55df00a0e8 (patch)
tree32ab3b32ec996f759c7e7dc94feb2d9e182ddbff
parentc358eab1eb68388f9cf4a921cd6ef316bb37a3a8 (diff)
downloadQt-28d0930593c6c04a7ef538353f8bee55df00a0e8.zip
Qt-28d0930593c6c04a7ef538353f8bee55df00a0e8.tar.gz
Qt-28d0930593c6c04a7ef538353f8bee55df00a0e8.tar.bz2
Fix Solaris build failure with the new qt_safe_() socket functions.
Reviewed-by: Thiago
-rw-r--r--src/network/socket/qnet_unix_p.h3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/network/socket/qnet_unix_p.h b/src/network/socket/qnet_unix_p.h
index b33d225..03ed3b4 100644
--- a/src/network/socket/qnet_unix_p.h
+++ b/src/network/socket/qnet_unix_p.h
@@ -138,7 +138,8 @@ static inline int qt_safe_listen(int s, int backlog)
static inline int qt_safe_connect(int sockfd, const struct sockaddr *addr, QT_SOCKLEN_T addrlen)
{
register int ret;
- EINTR_LOOP(ret, QT_SOCKET_CONNECT(sockfd, addr, addrlen));
+ // Solaris e.g. expects a non-const 2nd parameter
+ EINTR_LOOP(ret, QT_SOCKET_CONNECT(sockfd, const_cast<struct sockaddr *>(addr), addrlen));
return ret;
}
#undef QT_SOCKET_CONNECT