Commit bc0d62db authored by Howard Chu's avatar Howard Chu
Browse files

Revert "ITS#8847 more fallout from ldap_pvt_sockaddrstr move"

This reverts commit f2ddf89e.

Move Sockaddr def to ac/socket.h instead.
parent 3c62c94b
Pipeline #2282 passed with stage
in 46 minutes and 21 seconds
......@@ -234,6 +234,18 @@ LDAP_LUTIL_F( int ) lutil_getpeereid( int s, uid_t *, gid_t * );
#define LUTIL_GETPEEREID( s, uid, gid, bv ) lutil_getpeereid( s, uid, gid )
#endif
typedef union Sockaddr {
struct sockaddr sa_addr;
struct sockaddr_in sa_in_addr;
#ifdef LDAP_PF_INET6
struct sockaddr_storage sa_storage;
struct sockaddr_in6 sa_in6_addr;
#endif
#ifdef LDAP_PF_LOCAL
struct sockaddr_un sa_un_addr;
#endif
} Sockaddr;
/* DNS RFC defines max host name as 255. New systems seem to use 1024 */
#ifndef NI_MAXHOST
#define NI_MAXHOST 256
......
......@@ -178,22 +178,7 @@ ldap_pvt_get_hname LDAP_P((
#define LDAP_IPADDRLEN sizeof("IP=255.255.255.255:65336")
#endif
struct sockaddr_in;
struct sockaddr_in6;
struct sockaddr_storage;
struct sockaddr_un;
typedef union Sockaddr {
struct sockaddr sa_addr;
struct sockaddr_in sa_in_addr;
#ifdef LDAP_PF_INET6
struct sockaddr_storage sa_storage;
struct sockaddr_in6 sa_in6_addr;
#endif
#ifdef LDAP_PF_LOCAL
struct sockaddr_un sa_un_addr;
#endif
} Sockaddr;
typedef union Sockaddr Sockaddr;
LDAP_F (void)
ldap_pvt_sockaddrstr LDAP_P((
......
......@@ -30,6 +30,7 @@
#include "ldap_log.h"
#include "ldap_defaults.h"
#include "lber.h"
#include "ldap_pvt.h"
static FILE *log_file = NULL;
static int debug_lastc = '\n';
......
......@@ -19,7 +19,6 @@
#include <ac/stdlib.h>
#include <ac/string.h>
#include <ac/unistd.h>
#include <ac/socket.h>
#include <stdio.h>
......
......@@ -33,7 +33,6 @@
#include <ac/string.h>
#include <ac/unistd.h>
#include <ac/param.h>
#include <ac/socket.h>
#ifdef SLAPD_CRYPT
# include <ac/crypt.h>
......
......@@ -21,7 +21,6 @@
#include <ac/stdlib.h>
#include <ac/string.h>
#include <ac/unistd.h>
#include <ac/socket.h>
#ifdef HAVE_SASL_SASL_H
#include <sasl/sasl.h>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment