From: Todd C. Miller Date: Fri, 30 Apr 2010 19:13:47 +0000 (-0400) Subject: Use angle brackets when including headers that can only be found when X-Git-Tag: SUDO_1_8_0~675 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d346e509032f9c6f7468ddefcebb361607519302;p=sudo Use angle brackets when including headers that can only be found when an -I flag is specified. The files in the compat dir could get away with double quotes here but I've converted all the source files to use angle brackets for consistency. --- diff --git a/compat/getline.c b/compat/getline.c index f96be46e8..5e6edbcf6 100644 --- a/compat/getline.c +++ b/compat/getline.c @@ -36,7 +36,7 @@ #endif /* HAVE_STRING_H */ #include -#include "compat.h" +#include #ifndef LINE_MAX # define LINE_MAX 2048 diff --git a/compat/mksiglist.c b/compat/mksiglist.c index 31e8c87be..84d2ead4b 100644 --- a/compat/mksiglist.c +++ b/compat/mksiglist.c @@ -28,7 +28,7 @@ #endif /* STDC_HEADERS */ #include -#include "compat.h" +#include #if !defined(NSIG) # if defined(_NSIG) diff --git a/compat/nanosleep.c b/compat/nanosleep.c index c44d89577..9c33d11d6 100644 --- a/compat/nanosleep.c +++ b/compat/nanosleep.c @@ -29,7 +29,7 @@ #endif #include -#include "compat.h" +#include int nanosleep(const struct timespec *ts, struct timespec *rts) diff --git a/compat/strdup.c b/compat/strdup.c index 11d410e79..17e11f932 100644 --- a/compat/strdup.c +++ b/compat/strdup.c @@ -36,7 +36,7 @@ # include #endif /* HAVE_MALLOC_H && !STDC_HEADERS */ -#include "compat.h" +#include char * strdup(const char *src) diff --git a/compat/strndup.c b/compat/strndup.c index 4109d7341..d6a905d5b 100644 --- a/compat/strndup.c +++ b/compat/strndup.c @@ -36,7 +36,7 @@ # include #endif /* HAVE_MALLOC_H && !STDC_HEADERS */ -#include "compat.h" +#include char * strndup(const char *src, size_t maxlen) diff --git a/plugins/sample/sample_plugin.c b/plugins/sample/sample_plugin.c index f60214b14..772f9f83e 100644 --- a/plugins/sample/sample_plugin.c +++ b/plugins/sample/sample_plugin.c @@ -49,8 +49,8 @@ #include #include -#include "compat.h" -#include "missing.h" +#include +#include /* * Sample plugin module that allows any user who knows the password diff --git a/plugins/sudoers/boottime.c b/plugins/sudoers/boottime.c index f91c9850f..7f2f7d614 100644 --- a/plugins/sudoers/boottime.c +++ b/plugins/sudoers/boottime.c @@ -41,8 +41,8 @@ # include #endif -#include "compat.h" -#include "missing.h" +#include +#include /* * Fill in a struct timeval with the time the system booted. diff --git a/plugins/sudoers/getdate.c b/plugins/sudoers/getdate.c index 878fe5f40..961744517 100644 --- a/plugins/sudoers/getdate.c +++ b/plugins/sudoers/getdate.c @@ -51,7 +51,7 @@ #endif #include -#include "compat.h" +#include #define EPOCH 1970 diff --git a/plugins/sudoers/match.c b/plugins/sudoers/match.c index c523dfd90..33fdbcb1a 100644 --- a/plugins/sudoers/match.c +++ b/plugins/sudoers/match.c @@ -84,10 +84,10 @@ #include #ifndef HAVE_FNMATCH -# include "compat/fnmatch.h" +# include #endif /* HAVE_FNMATCH */ #ifndef HAVE_EXTENDED_GLOB -# include "compat/glob.h" +# include #endif /* HAVE_EXTENDED_GLOB */ #ifdef USING_NONUNIX_GROUPS # include "nonunix.h" diff --git a/plugins/sudoers/sudoreplay.c b/plugins/sudoers/sudoreplay.c index e959ec6af..ad484f936 100644 --- a/plugins/sudoers/sudoreplay.c +++ b/plugins/sudoers/sudoreplay.c @@ -83,10 +83,10 @@ #include -#include "compat.h" -#include "alloc.h" -#include "error.h" -#include "missing.h" +#include +#include +#include +#include /* For getopt(3) */ extern char *optarg; diff --git a/plugins/sudoers/timestr.c b/plugins/sudoers/timestr.c index 7649f113e..28317bfeb 100644 --- a/plugins/sudoers/timestr.c +++ b/plugins/sudoers/timestr.c @@ -28,7 +28,7 @@ #endif /* STDC_HEADERS */ #include -#include "compat.h" +#include char *get_timestr(time_t, int); diff --git a/plugins/sudoers/vasgroups.c b/plugins/sudoers/vasgroups.c index 33eb40cdd..f1b1c6490 100644 --- a/plugins/sudoers/vasgroups.c +++ b/plugins/sudoers/vasgroups.c @@ -40,7 +40,6 @@ #include -#include "compat.h" #include "logging.h" #include "nonunix.h" #include "parse.h" diff --git a/src/alloc.c b/src/alloc.c index 0811ef71e..979021869 100644 --- a/src/alloc.c +++ b/src/alloc.c @@ -46,9 +46,9 @@ # include #endif -#include "compat.h" -#include "alloc.h" -#include "error.h" +#include +#include +#include /* * If there is no SIZE_MAX or SIZE_T_MAX we have to assume that size_t diff --git a/src/atobool.c b/src/atobool.c index 9f02ebe0d..e442b49f4 100644 --- a/src/atobool.c +++ b/src/atobool.c @@ -39,8 +39,8 @@ # endif #endif /* HAVE_STRING_H */ -#include "compat.h" -#include "missing.h" +#include +#include int atobool(const char *str) diff --git a/src/audit.c b/src/audit.c index 0fc4a727a..9356e25b5 100644 --- a/src/audit.c +++ b/src/audit.c @@ -28,7 +28,7 @@ #endif /* STDC_HEADERS */ #include -#include "compat.h" +#include #include "logging.h" #ifdef HAVE_BSM_AUDIT diff --git a/src/lbuf.c b/src/lbuf.c index 9ea511afe..0b2d26fb4 100644 --- a/src/lbuf.c +++ b/src/lbuf.c @@ -47,11 +47,11 @@ # include #endif -#include "compat.h" -#include "alloc.h" -#include "error.h" -#include "missing.h" -#include "lbuf.h" +#include +#include +#include +#include +#include void lbuf_init(struct lbuf *lbuf, int (*output)(const char *), diff --git a/src/list.c b/src/list.c index 3d35ed48f..f077291ac 100644 --- a/src/list.c +++ b/src/list.c @@ -29,10 +29,10 @@ # endif #endif /* STDC_HEADERS */ -#include "compat.h" -#include "list.h" +#include +#include #ifdef DEBUG -# include "error.h" +# include #endif struct list_proto { diff --git a/src/sesh.c b/src/sesh.c index 38a834908..a288cdb73 100644 --- a/src/sesh.c +++ b/src/sesh.c @@ -27,7 +27,7 @@ #include #include -#include "compat.h" +#include int main (int argc, char *argv[]) diff --git a/src/term.c b/src/term.c index 6e7f614f7..71f924b69 100644 --- a/src/term.c +++ b/src/term.c @@ -43,7 +43,7 @@ # include #endif /* HAVE_TERMIOS_H */ -#include "compat.h" +#include #ifndef TCSASOFT # define TCSASOFT 0 diff --git a/src/ttysize.c b/src/ttysize.c index 3054e653e..5517faa87 100644 --- a/src/ttysize.c +++ b/src/ttysize.c @@ -38,7 +38,7 @@ # include #endif -#include "compat.h" +#include #if !defined(TIOCGSIZE) && defined(TIOCGWINSZ) # define TIOCGSIZE TIOCGWINSZ