summaryrefslogtreecommitdiff
path: root/utils
diff options
context:
space:
mode:
authorLuigi Rizzo <rizzo@icir.org>2007-11-16 20:04:58 +0000
committerLuigi Rizzo <rizzo@icir.org>2007-11-16 20:04:58 +0000
commitfdb7f7ba3da0b1bb02c782eba68aa1fa4ba96800 (patch)
treec012d8f76915d410cf7446b1efc51e3c2e3f5e95 /utils
parentfd7b3e7261ab74af7e8a98f5090bef00c31de8a5 (diff)
Start untangling header inclusion in a way that does not affect
build times - tested, there is no measureable difference before and after this commit. In this change: use asterisk/compat.h to include a small set of system headers: inttypes.h, unistd.h, stddef.h, stddint.h, sys/types.h, stdarg.h, stdlib.h, alloca.h, stdio.h Where available, the inclusion is conditional on HAVE_FOO_H as determined by autoconf. Normally, source files should not include any of the above system headers, and instead use either "asterisk.h" or "asterisk/compat.h" which does it better. For the time being I have left alone second-level directories (main/db1-ast, etc.). git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@89333 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'utils')
-rw-r--r--utils/ael_main.c5
-rw-r--r--utils/hashtest.c9
-rw-r--r--utils/hashtest2.c9
3 files changed, 0 insertions, 23 deletions
diff --git a/utils/ael_main.c b/utils/ael_main.c
index 8955aa045..0e82e2b01 100644
--- a/utils/ael_main.c
+++ b/utils/ael_main.c
@@ -1,8 +1,3 @@
-#include <sys/types.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <stdarg.h>
-#include <string.h>
#include <locale.h>
#include <ctype.h>
#include <errno.h>
diff --git a/utils/hashtest.c b/utils/hashtest.c
index 18dc713f4..dec2e7cd5 100644
--- a/utils/hashtest.c
+++ b/utils/hashtest.c
@@ -31,19 +31,10 @@
#include "asterisk.h"
ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
-#include <sys/types.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <stdarg.h>
-#ifdef HAVE_ALLOCA_H
-#include <alloca.h>
-#endif
-#include <string.h>
#include <pthread.h>
#include <sys/stat.h>
#include <signal.h>
#include <errno.h>
-#include <unistd.h>
#include "asterisk/lock.h"
#include "asterisk/hashtab.h"
#include "asterisk/channel.h"
diff --git a/utils/hashtest2.c b/utils/hashtest2.c
index aaaeb06a3..956453c07 100644
--- a/utils/hashtest2.c
+++ b/utils/hashtest2.c
@@ -32,19 +32,10 @@
ASTERISK_FILE_VERSION(__FILE__, "$Revision$")
-#include <sys/types.h>
-#include <stdio.h>
-#include <stdlib.h>
-#include <stdarg.h>
-#ifdef HAVE_ALLOCA_H
-#include <alloca.h>
-#endif
-#include <string.h>
#include <pthread.h>
#include <sys/stat.h>
#include <signal.h>
#include <errno.h>
-#include <unistd.h>
#include "asterisk/compat.h"
#include "asterisk/lock.h"