lmsg/sockfix.hh

00001 //  This fixes a major stupidity in the solaris socket header when used 
00002 //  with a non-solaris compiler (e.g. g++).
00003 //
00004 //  The solaris socket header defines the following symbols:
00005 //      bind    __xnet_bind
00006 //      connect __xnet_connect
00007 //
00008 #if defined(__cplusplus) && defined(sun)
00009 
00010 #ifdef bind
00011 #undef bind
00012 inline int 
00013 bind(int s, struct sockaddr* a, socklen_t l) {
00014     return __xnet_bind(s, a, l);
00015 }
00016 #endif
00017 
00018 #ifdef connect
00019 #undef connect
00020 inline int 
00021 connect(int s, struct sockaddr* a, socklen_t l) {
00022     return __xnet_connect(s, a, l);
00023 }
00024 #endif
00025 
00026 #endif // defined(__cplusplus) && defined(sun)
00027 

Generated on Sun Mar 8 19:20:50 2009 for dmt by  doxygen 1.5.4