]> git.ipfire.org Git - thirdparty/asterisk.git/commitdiff
remove duplicate headers.
authorLuigi Rizzo <rizzo@icir.org>
Fri, 16 Nov 2007 20:28:19 +0000 (20:28 +0000)
committerLuigi Rizzo <rizzo@icir.org>
Fri, 16 Nov 2007 20:28:19 +0000 (20:28 +0000)
Properly check for netdb.h (there is actually tens of places to fix)

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@89335 65c4cc65-6c06-0410-ace0-fbb531ad65f3

main/acl.c
main/asterisk.c

index d803290e6c54329d7411154a56be6d08a2fef3fc..f82a0805cfc46bad3229b9d019bc8805c13893d6 100644 (file)
@@ -30,13 +30,11 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 #include <sys/time.h>
 #include <signal.h>
 #include <errno.h>
-#include <unistd.h>
 #include <netinet/in.h>
 #include <arpa/inet.h>
 #include <sys/socket.h>
 #include <netdb.h>
 #include <net/if.h>
-#include <netinet/in.h>
 #include <netinet/in_systm.h>
 #include <netinet/ip.h>
 #include <sys/ioctl.h>
index a94972cc5c5548ce3144fdf5cd4a65881e4a830e..1f03484d24405038ca846ba44aa42d10ef584b5f 100644 (file)
@@ -70,7 +70,6 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 #include <sys/socket.h>
 #include <sys/un.h>
 #include <sys/wait.h>
-#include <string.h>
 #include <errno.h>
 #include <ctype.h>
 #include <sys/resource.h>
@@ -88,13 +87,13 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
 #endif /* linux */
 #include <regex.h>
 
-#if  defined(__FreeBSD__) || defined( __NetBSD__ ) || defined(SOLARIS)
+#ifdef HAVE_NETDB_H
 #include <netdb.h>
+#endif
 #if defined(SOLARIS)
 int daemon(int, int);  /* defined in libresolv of all places */
 #include <sys/loadavg.h>
 #endif
-#endif
 
 #include "asterisk/logger.h"
 #include "asterisk/options.h"