2011-03-30 09:00:22 +02:00
|
|
|
From 642b5d51f4fec7047de3692c5da3521a6a749ec2 Mon Sep 17 00:00:00 2001
|
2010-08-27 21:45:34 +02:00
|
|
|
From: Ralf Haferkamp <rhafer@suse.de>
|
|
|
|
Date: Wed, 16 Jun 2010 14:08:03 +0200
|
|
|
|
Subject: libldap use gethostbyname_r
|
|
|
|
|
|
|
|
|
|
|
|
diff --git a/libraries/libldap/util-int.c b/libraries/libldap/util-int.c
|
2011-02-16 14:51:13 +01:00
|
|
|
index d2b4ae8..3180d74 100644
|
2010-08-27 21:45:34 +02:00
|
|
|
--- a/libraries/libldap/util-int.c
|
|
|
|
+++ b/libraries/libldap/util-int.c
|
|
|
|
@@ -52,7 +52,7 @@ extern int h_errno;
|
|
|
|
#ifndef LDAP_R_COMPILE
|
|
|
|
# undef HAVE_REENTRANT_FUNCTIONS
|
|
|
|
# undef HAVE_CTIME_R
|
|
|
|
-# undef HAVE_GETHOSTBYNAME_R
|
|
|
|
+/* # undef HAVE_GETHOSTBYNAME_R */
|
|
|
|
# undef HAVE_GETHOSTBYADDR_R
|
|
|
|
|
|
|
|
#else
|
2011-02-16 14:51:13 +01:00
|
|
|
@@ -312,7 +312,7 @@ ldap_pvt_csnstr(char *buf, size_t len, unsigned int replica, unsigned int mod)
|
2010-08-27 21:45:34 +02:00
|
|
|
#define BUFSTART (1024-32)
|
|
|
|
#define BUFMAX (32*1024-32)
|
|
|
|
|
|
|
|
-#if defined(LDAP_R_COMPILE)
|
|
|
|
+#if defined(LDAP_R_COMPILE) || defined(HAVE_GETHOSTBYNAME_R)
|
|
|
|
static char *safe_realloc( char **buf, int len );
|
|
|
|
|
|
|
|
#if !(defined(HAVE_GETHOSTBYNAME_R) && defined(HAVE_GETHOSTBYADDR_R))
|
|
|
|
--
|
2011-02-16 14:51:13 +01:00
|
|
|
1.7.3.4
|
2010-08-27 21:45:34 +02:00
|
|
|
|