X-Git-Url: https://git.sur5r.net/?a=blobdiff_plain;f=libraries%2Flibldap%2Fos-ip.c;h=0084743d8498fe922a32e9aade7835416abbe656;hb=70092b38fb23b9141a2b8414fb5a9c5200f3c12d;hp=3ebe3e719d7c57f99d9a7bddcc7ff71a3e6ee034;hpb=b7bd4368d9311558784339de50a3085af65ad31c;p=openldap diff --git a/libraries/libldap/os-ip.c b/libraries/libldap/os-ip.c index 3ebe3e719d..0084743d84 100644 --- a/libraries/libldap/os-ip.c +++ b/libraries/libldap/os-ip.c @@ -152,7 +152,7 @@ ldap_pvt_is_socket_ready(LDAP *ld, int s) #if defined( notyet ) /* && defined( SO_ERROR ) */ { int so_errno; - int dummy = sizeof(so_errno); + socklen_t dummy = sizeof(so_errno); if ( getsockopt( s, SOL_SOCKET, SO_ERROR, &so_errno, &dummy ) == AC_SOCKET_ERROR ) { @@ -170,7 +170,7 @@ ldap_pvt_is_socket_ready(LDAP *ld, int s) /* error slippery */ struct sockaddr_in sin; char ch; - int dummy = sizeof(sin); + socklen_t dummy = sizeof(sin); if ( getpeername( s, (struct sockaddr *) &sin, &dummy ) == AC_SOCKET_ERROR ) { @@ -344,7 +344,7 @@ ldap_connect_to_host(LDAP *ld, Sockbuf *sb, hints.ai_socktype = socktype; snprintf(serv, sizeof serv, "%d", port ); - if ( err = getaddrinfo(host, serv, &hints, &res) ) { + if ( ( err = getaddrinfo(host, serv, &hints, &res) ) ) { osip_debug(ld, "ldap_connect_to_host: getaddrinfo failed: %s\n", AC_GAI_STRERROR(err), 0, 0); return -1;