From: Kurt Zeilenga Date: Mon, 26 Jun 2000 05:23:33 +0000 (+0000) Subject: Add missing sockerr call X-Git-Tag: LDBM_PRE_GIANT_RWLOCK~2520 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=8670bb6ba29c2d92b51a15ba61137bea394ae310;p=openldap Add missing sockerr call --- diff --git a/servers/slapd/daemon.c b/servers/slapd/daemon.c index 7e9c6931b9..88dcd60d46 100644 --- a/servers/slapd/daemon.c +++ b/servers/slapd/daemon.c @@ -279,6 +279,7 @@ static Listener * open_listener( const char* url ) do { l.sl_sd = socket( sai->ai_family, sai->ai_socktype, sai->ai_protocol); if ( l.sl_sd == AC_SOCKET_INVALID ) { + int err = sock_errno(); Debug( LDAP_DEBUG_ANY, "daemon: socket() failed errno=%d (%s)\n", err, sock_errstr(err), 0 ); @@ -437,7 +438,7 @@ static Listener * open_listener( const char* url ) # ifdef LDAP_PF_UNIX case AF_UNIX: if ( chmod( (char *)sai->ai_addr, S_IRWXU ) < 0 ) { - err = sock_errno(); + int err = sock_errno(); Debug( LDAP_DEBUG_ANY, "daemon: fchmod(%ld) failed errno=%d (%s)", (long) l.sl_sd, err, sock_errstr(err) ); tcp_close( l.sl_sd );