On Thursday, 9 de February de 2012 17.45.01, gemfield wrote: > Hi, > > I found many codeing style like below in Qt source: > > 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, const_cast<struct sockaddr > *>(addr), addrlen)); return ret; > } > #undef QT_SOCKET_CONNECT > #define QT_SOCKET_CONNECT qt_safe_connect > > What does QT_SOCKET_CONNECT macro really mean? > > I think it shoule be a Linux API-connect,but I can't find it.
You did not search well enough. mkspecs/common/posix/qplatformdefs.h:#define QT_SOCKET_CONNECT ::connect mkspecs/solaris-cc-64/qplatformdefs.h:#undef QT_SOCKET_CONNECT mkspecs/solaris-cc-64/qplatformdefs.h:#define QT_SOCKET_CONNECT qt_socket_connect mkspecs/solaris-cc/qplatformdefs.h:#undef QT_SOCKET_CONNECT mkspecs/solaris-cc/qplatformdefs.h:#define QT_SOCKET_CONNECT qt_socket_connect mkspecs/solaris-g++-64/qplatformdefs.h:#undef QT_SOCKET_CONNECT mkspecs/solaris-g++-64/qplatformdefs.h:#define QT_SOCKET_CONNECT qt_socket_connect mkspecs/solaris-g++/qplatformdefs.h:#undef QT_SOCKET_CONNECT mkspecs/solaris-g++/qplatformdefs.h:#define QT_SOCKET_CONNECT qt_socket_connect mkspecs/unsupported/integrity-ghs/qplatformdefs.h:#define QT_SOCKET_CONNECT ::connect mkspecs/unsupported/vxworks-simpentium-g++/qplatformdefs.h:#undef QT_SOCKET_CONNECT mkspecs/unsupported/vxworks-simpentium-g++/qplatformdefs.h:#define QT_SOCKET_CONNECT(sd, to, tolen) \ -- Thiago Macieira - thiago (AT) macieira.info - thiago (AT) kde.org Software Architect - Intel Open Source Technology Center PGP/GPG: 0x6EF45358; fingerprint: E067 918B B660 DBD1 105C 966C 33F5 F005 6EF4 5358
signature.asc
Description: This is a digitally signed message part.
_______________________________________________ Interest mailing list Interest@qt-project.org http://lists.qt-project.org/mailman/listinfo/interest