From: Pierre Habouzit Date: Fri, 17 Nov 2006 00:40:55 +0000 (+0100) Subject: more include simplifications X-Git-Url: http://git.madism.org/?p=apps%2Fmadmutt.git;a=commitdiff_plain;h=d8aeb41018aaf2f85fbd937278ffdd94164e236e more include simplifications Signed-off-by: Pierre Habouzit --- diff --git a/imap/imap_private.h b/imap/imap_private.h index 2a7a1f9..5486c21 100644 --- a/imap/imap_private.h +++ b/imap/imap_private.h @@ -11,12 +11,10 @@ #ifndef _IMAP_PRIVATE_H #define _IMAP_PRIVATE_H 1 -#include - +#include #include #include "imap.h" -#include /* -- symbols -- */ #define IMAP_PORT 143 diff --git a/imap/mx_imap.h b/imap/mx_imap.h index 526bbf9..e4758c3 100644 --- a/imap/mx_imap.h +++ b/imap/mx_imap.h @@ -11,8 +11,6 @@ #ifndef _IMAP_MX_H #define _IMAP_MX_H -#include - #include "mx.h" int imap_is_magic (const char*, struct stat*); diff --git a/lib-lib/lib-lib.h b/lib-lib/lib-lib.h index e969bb5..8cd91c2 100644 --- a/lib-lib/lib-lib.h +++ b/lib-lib/lib-lib.h @@ -46,6 +46,7 @@ #ifdef HAVE_UNISTD_H # include #endif + #if HAVE_STDINT_H # include #elif HAVE_INTTYPES_H @@ -60,6 +61,11 @@ #include #endif +#ifndef _POSIX_PATH_MAX +#include +#endif + + #include "macros.h" #include "mem.h" diff --git a/lib-mime/mime.h b/lib-mime/mime.h index 74530cf..10b4c86 100644 --- a/lib-mime/mime.h +++ b/lib-mime/mime.h @@ -29,13 +29,6 @@ #ifndef MUTT_LIB_MIME_MIME_H #define MUTT_LIB_MIME_MIME_H -#if HAVE_CONFIG_H -# include "config.h" -#endif - -#include -#include - #include "mime-types.h" #include "mime-token.h" diff --git a/lib-sys/unix.h b/lib-sys/unix.h index 5e1b618..bfc16c0 100644 --- a/lib-sys/unix.h +++ b/lib-sys/unix.h @@ -20,10 +20,8 @@ #ifndef MUTT_LIB_SYS_UNIX_H #define MUTT_LIB_SYS_UNIX_H -#include -#include - #include +#include ssize_t mutt_gecos_name(char *dst, ssize_t n, struct passwd *pw, regex_t *rx); int getdnsdomainname(char *, ssize_t); diff --git a/lib-ui/curses.h b/lib-ui/curses.h index c468446..33286c3 100644 --- a/lib-ui/curses.h +++ b/lib-ui/curses.h @@ -10,6 +10,7 @@ #ifndef _MUTT_CURSES_H #define _MUTT_CURSES_H +#include #include "mutt.h" #ifdef USE_SLANG_CURSES diff --git a/lib/list.h b/lib/list.h index a63b528..3f701be 100644 --- a/lib/list.h +++ b/lib/list.h @@ -16,8 +16,6 @@ #ifndef _LIB_LIST_H #define _LIB_LIST_H -#include - typedef struct list2_t { void** data; ssize_t length; diff --git a/mbox.h b/mbox.h index 4959a28..e3bc8ca 100644 --- a/mbox.h +++ b/mbox.h @@ -15,8 +15,6 @@ #ifndef _MBOX_H #define _MBOX_H -#include - #include "mx.h" /* TODO all of these must disappear to achieve good information hiding */ diff --git a/mh.h b/mh.h index a6b12eb..4764f7a 100644 --- a/mh.h +++ b/mh.h @@ -15,8 +15,6 @@ #ifndef _MH_H #define _MH_H -#include - #include "mx.h" /* TODO all of these must disappear to achieve good information hiding */ diff --git a/mutt.h b/mutt.h index 5931f2f..39bd444 100644 --- a/mutt.h +++ b/mutt.h @@ -11,20 +11,7 @@ #ifndef _MUTT_H #define _MUTT_H -#ifdef HAVE_CONFIG_H -#include "config.h" -#endif - -#include -#include -#include - -#ifndef _POSIX_PATH_MAX -#include -#endif - #include - #include #define MUTT_VERSION (VERSION) diff --git a/mutt_idna.h b/mutt_idna.h index 58dbd2f..777130f 100644 --- a/mutt_idna.h +++ b/mutt_idna.h @@ -10,12 +10,7 @@ #ifndef _MUTT_IDNA_H # define _MUTT_IDNA_H -#if HAVE_CONFIG_H -# include "config.h" -#endif - #include -#include "charset.h" #define MI_MAY_BE_IRREVERSIBLE (1 << 0) diff --git a/mx.h b/mx.h index 8f0a365..60f7782 100644 --- a/mx.h +++ b/mx.h @@ -17,10 +17,7 @@ #ifndef _MX_H #define _MX_H -#include #include -#include - #include "mutt.h" /* diff --git a/nntp/nntp.h b/nntp/nntp.h index 8ddac27..3e89c39 100644 --- a/nntp/nntp.h +++ b/nntp/nntp.h @@ -15,8 +15,6 @@ #include #include "mx.h" -#include - #define NNTP_PORT 119 #define NNTP_SSL_PORT 563 diff --git a/pop/pop.h b/pop/pop.h index f1a570a..3d3f4b5 100644 --- a/pop/pop.h +++ b/pop/pop.h @@ -11,9 +11,9 @@ #define _POP_H 1 #include +#include #include "mx.h" -#include #define POP_PORT 110 #define POP_SSL_PORT 995 diff --git a/protos.h b/protos.h index d07d699..bd3afee 100644 --- a/protos.h +++ b/protos.h @@ -7,18 +7,6 @@ * please see the file GPL in the top level source directory. */ -#ifdef HAVE_CONFIG_H -# include "config.h" -#endif - -#include - -#if HAVE_STDINT_H -#include -#elif HAVE_INTTYPES_H -#include -#endif - #define MoreArgs(p) (*p->dptr && *p->dptr != ';' && *p->dptr != '#') typedef const char *format_t (char *, ssize_t, char, const char *, diff --git a/recvattach.h b/recvattach.h index 438e2fc..96b28d2 100644 --- a/recvattach.h +++ b/recvattach.h @@ -10,7 +10,6 @@ #define _MUTT_RECVATTACH_H #include - #include #include "mutt.h" diff --git a/xterm.h b/xterm.h index 37dac4b..ffb162d 100644 --- a/xterm.h +++ b/xterm.h @@ -7,7 +7,6 @@ #define MUTT_XTERM_H #include -#include /* sets the current xterm's title */ static inline void mutt_xterm_set_title(const char *title) {