]> jfr.im git - irc/znc/Csocket.git/commitdiff
win32: fix another failure if _WIN32_WINNT >= XPSP2
authorIngmar Runge <redacted>
Tue, 11 Jul 2017 14:39:40 +0000 (16:39 +0200)
committerIngmar Runge <redacted>
Tue, 11 Jul 2017 14:39:40 +0000 (16:39 +0200)
Csocket.cc
Csocket.h

index 1d5d7941473316176a146db551b8e924f47e0dea..143614fdceed066893005918e6e1193f9266f15b 100644 (file)
@@ -526,7 +526,7 @@ int CGetAddrInfo::Finish()
        return( ETIMEDOUT );
 }
 
-int GetAddrInfo( const CS_STRING & sHostname, Csock * pSock, CSSockAddr & csSockAddr )
+int CS_GetAddrInfo( const CS_STRING & sHostname, Csock * pSock, CSSockAddr & csSockAddr )
 {
 #ifdef USE_GETHOSTBYNAME
        if( pSock )
@@ -1414,7 +1414,7 @@ bool Csock::Listen( uint16_t iPort, int iMaxConns, const CS_STRING & sBindHost,
                else
                {
                        // if not detaching, then must block to do DNS resolution, so might as well use internal resolver
-                       if( ::GetAddrInfo( m_sBindHost, this, m_address ) != 0 )
+                       if( ::CS_GetAddrInfo( m_sBindHost, this, m_address ) != 0 )
                        {
                                CallSockError( EADDRNOTAVAIL );
                                return( false );
@@ -3073,7 +3073,7 @@ int Csock::GetAddrInfo( const CS_STRING & sHostname, CSSockAddr & csSockAddr )
        }
        return( EAGAIN );
 #else /* HAVE_C_ARES */
-       return( ::GetAddrInfo( sHostname, this, csSockAddr ) );
+       return( ::CS_GetAddrInfo( sHostname, this, csSockAddr ) );
 #endif /* HAVE_C_ARES */
 }
 
index c64426524c822d6da98b8d8410b79925f70846e3..ddff5a27edfac4475f573c802c57a3fcc6a4b5c7 100644 (file)
--- a/Csocket.h
+++ b/Csocket.h
@@ -300,7 +300,7 @@ private:
 };
 
 //! backwards compatible wrapper around CGetAddrInfo and gethostbyname
-int GetAddrInfo( const CS_STRING & sHostname, Csock * pSock, CSSockAddr & csSockAddr );
+int CS_GetAddrInfo( const CS_STRING & sHostname, Csock * pSock, CSSockAddr & csSockAddr );
 
 /**
  * This returns the [ex_]data index position for SSL objects only. If you want to tie more data