diff options
| author | 2015-12-31 16:50:29 +0000 | |
|---|---|---|
| committer | 2015-12-31 16:50:29 +0000 | |
| commit | 2317ec67b0fa8cbb4cdee40097f28e1a0c3dd5ef (patch) | |
| tree | 9020511e61396f8abe37cb82f9e04c20af4ef513 | |
| parent | Include only needed header files per each source file (diff) | |
| download | wireguard-openbsd-2317ec67b0fa8cbb4cdee40097f28e1a0c3dd5ef.tar.xz wireguard-openbsd-2317ec67b0fa8cbb4cdee40097f28e1a0c3dd5ef.zip | |
Include only needed header files per each source file
OK tb@
| -rw-r--r-- | games/atc/extern.c | 9 | ||||
| -rw-r--r-- | games/atc/extern.h | 7 | ||||
| -rw-r--r-- | games/atc/grammar.y | 6 | ||||
| -rw-r--r-- | games/atc/graphics.c | 8 | ||||
| -rw-r--r-- | games/atc/include.h | 69 | ||||
| -rw-r--r-- | games/atc/input.c | 12 | ||||
| -rw-r--r-- | games/atc/list.c | 6 | ||||
| -rw-r--r-- | games/atc/log.c | 14 | ||||
| -rw-r--r-- | games/atc/main.c | 11 | ||||
| -rw-r--r-- | games/atc/struct.h | 4 | ||||
| -rw-r--r-- | games/atc/update.c | 7 |
11 files changed, 65 insertions, 88 deletions
diff --git a/games/atc/extern.c b/games/atc/extern.c index 5e8f3c55165..c6437a90ecb 100644 --- a/games/atc/extern.c +++ b/games/atc/extern.c @@ -1,4 +1,4 @@ -/* $OpenBSD: extern.c,v 1.6 2014/12/09 05:01:14 deraadt Exp $ */ +/* $OpenBSD: extern.c,v 1.7 2015/12/31 16:50:29 mestre Exp $ */ /* $NetBSD: extern.c,v 1.4 1995/04/27 21:22:19 mycroft Exp $ */ /*- @@ -42,7 +42,12 @@ * For more info on this and all of my stuff, mail edjames@berkeley.edu. */ -#include "include.h" +#include <stdio.h> +#include <termios.h> +#include <time.h> + +#include "def.h" +#include "extern.h" char GAMES[] = "Game_List"; diff --git a/games/atc/extern.h b/games/atc/extern.h index 9dc0c15f48c..8396b207ca0 100644 --- a/games/atc/extern.h +++ b/games/atc/extern.h @@ -1,4 +1,4 @@ -/* $OpenBSD: extern.h,v 1.10 2015/12/26 00:26:39 mestre Exp $ */ +/* $OpenBSD: extern.h,v 1.11 2015/12/31 16:50:29 mestre Exp $ */ /* $NetBSD: extern.h,v 1.4 1995/04/27 21:22:22 mycroft Exp $ */ /*- @@ -44,6 +44,11 @@ * For more info on this and all of my stuff, mail edjames@berkeley.edu. */ +#include <curses.h> + +#include "def.h" +#include "struct.h" + extern char GAMES[]; extern const char *file; diff --git a/games/atc/grammar.y b/games/atc/grammar.y index 0ddc9091e5a..19442905707 100644 --- a/games/atc/grammar.y +++ b/games/atc/grammar.y @@ -1,4 +1,4 @@ -/* $OpenBSD: grammar.y,v 1.7 2015/02/18 22:33:51 tedu Exp $ */ +/* $OpenBSD: grammar.y,v 1.8 2015/12/31 16:50:29 mestre Exp $ */ /* $NetBSD: grammar.y,v 1.3 1995/03/21 15:03:59 cgd Exp $ */ /*- @@ -58,7 +58,9 @@ } %{ -#include "include.h" +#include "def.h" +#include "extern.h" +#include "y.tab.h" int errors = 0; int line = 1; diff --git a/games/atc/graphics.c b/games/atc/graphics.c index eb8fa104ac8..43078e533ee 100644 --- a/games/atc/graphics.c +++ b/games/atc/graphics.c @@ -1,4 +1,4 @@ -/* $OpenBSD: graphics.c,v 1.10 2015/11/04 21:22:10 tedu Exp $ */ +/* $OpenBSD: graphics.c,v 1.11 2015/12/31 16:50:29 mestre Exp $ */ /* $NetBSD: graphics.c,v 1.3 1995/03/21 15:04:04 cgd Exp $ */ /*- @@ -42,8 +42,12 @@ * For more info on this and all of my stuff, mail edjames@berkeley.edu. */ +#include <curses.h> #include <err.h> -#include "include.h" +#include <stdlib.h> + +#include "def.h" +#include "extern.h" #define C_TOPBOTTOM '-' #define C_LEFTRIGHT '|' diff --git a/games/atc/include.h b/games/atc/include.h index d1a2b809087..e69de29bb2d 100644 --- a/games/atc/include.h +++ b/games/atc/include.h @@ -1,69 +0,0 @@ -/* $OpenBSD: include.h,v 1.8 2015/12/15 18:40:54 tb Exp $ */ -/* $NetBSD: include.h,v 1.5 1995/04/27 21:22:23 mycroft Exp $ */ - -/*- - * Copyright (c) 1990, 1993 - * The Regents of the University of California. All rights reserved. - * - * This code is derived from software contributed to Berkeley by - * Ed James. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in the - * documentation and/or other materials provided with the distribution. - * 3. Neither the name of the University nor the names of its contributors - * may be used to endorse or promote products derived from this software - * without specific prior written permission. - * - * THIS SOFTWARE IS PROVIDED BY THE REGENTS AND CONTRIBUTORS ``AS IS'' AND - * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE - * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE - * ARE DISCLAIMED. IN NO EVENT SHALL THE REGENTS OR CONTRIBUTORS BE LIABLE - * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL - * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS - * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) - * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY - * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF - * SUCH DAMAGE. - * - * @(#)include.h 8.1 (Berkeley) 5/31/93 - */ - -/* - * Copyright (c) 1987 by Ed James, UC Berkeley. All rights reserved. - * - * Copy permission is hereby granted provided that this notice is - * retained on all partial or complete copies. - * - * For more info on this and all of my stuff, mail edjames@berkeley.edu. - */ - -#include <sys/types.h> -#include <sys/stat.h> -#include <sys/time.h> -#include <sys/utsname.h> -#include <sys/wait.h> - -#include <ctype.h> -#include <curses.h> -#include <err.h> -#include <errno.h> -#include <fcntl.h> -#include <limits.h> -#include <math.h> -#include <signal.h> -#include <stdio.h> -#include <stdlib.h> -#include <string.h> -#include <termios.h> -#include <unistd.h> - -#include "def.h" -#include "struct.h" -#include "extern.h" diff --git a/games/atc/input.c b/games/atc/input.c index 6528902b117..0d2439d6048 100644 --- a/games/atc/input.c +++ b/games/atc/input.c @@ -1,4 +1,4 @@ -/* $OpenBSD: input.c,v 1.12 2009/10/27 23:59:23 deraadt Exp $ */ +/* $OpenBSD: input.c,v 1.13 2015/12/31 16:50:29 mestre Exp $ */ /* $NetBSD: input.c,v 1.4 1995/04/27 21:22:24 mycroft Exp $ */ /*- @@ -42,8 +42,14 @@ * For more info on this and all of my stuff, mail edjames@berkeley.edu. */ -#include "include.h" -#include "pathnames.h" +#include <ctype.h> +#include <math.h> +#include <stdlib.h> +#include <string.h> +#include <termios.h> + +#include "def.h" +#include "extern.h" #define MAXRULES 6 #define MAXDEPTH 15 diff --git a/games/atc/list.c b/games/atc/list.c index 310124ec6f0..e86bb79d05e 100644 --- a/games/atc/list.c +++ b/games/atc/list.c @@ -1,4 +1,4 @@ -/* $OpenBSD: list.c,v 1.8 2015/08/22 14:47:41 deraadt Exp $ */ +/* $OpenBSD: list.c,v 1.9 2015/12/31 16:50:29 mestre Exp $ */ /* $NetBSD: list.c,v 1.3 1995/03/21 15:04:18 cgd Exp $ */ /*- @@ -42,7 +42,9 @@ * For more info on this and all of my stuff, mail edjames@berkeley.edu. */ -#include "include.h" +#include <stdlib.h> + +#include "extern.h" PLANE * newplane(void) diff --git a/games/atc/log.c b/games/atc/log.c index 575a9264f67..56fb1cfddb0 100644 --- a/games/atc/log.c +++ b/games/atc/log.c @@ -1,4 +1,4 @@ -/* $OpenBSD: log.c,v 1.20 2015/11/29 15:23:38 tb Exp $ */ +/* $OpenBSD: log.c,v 1.21 2015/12/31 16:50:29 mestre Exp $ */ /* $NetBSD: log.c,v 1.3 1995/03/21 15:04:21 cgd Exp $ */ /*- @@ -42,7 +42,17 @@ * For more info on this and all of my stuff, mail edjames@berkeley.edu. */ -#include "include.h" +#include <sys/stat.h> +#include <sys/types.h> + +#include <err.h> +#include <errno.h> +#include <fcntl.h> +#include <stdlib.h> +#include <string.h> +#include <unistd.h> + +#include "extern.h" #include "pathnames.h" static FILE *score_fp; diff --git a/games/atc/main.c b/games/atc/main.c index d67a5f454ad..2d8526f9345 100644 --- a/games/atc/main.c +++ b/games/atc/main.c @@ -1,4 +1,4 @@ -/* $OpenBSD: main.c,v 1.25 2015/11/29 15:23:38 tb Exp $ */ +/* $OpenBSD: main.c,v 1.26 2015/12/31 16:50:29 mestre Exp $ */ /* $NetBSD: main.c,v 1.4 1995/04/27 21:22:25 mycroft Exp $ */ /*- @@ -42,7 +42,14 @@ * For more info on this and all of my stuff, mail edjames@berkeley.edu. */ -#include "include.h" +#include <err.h> +#include <signal.h> +#include <stdlib.h> +#include <string.h> +#include <termios.h> +#include <unistd.h> + +#include "extern.h" #include "pathnames.h" int diff --git a/games/atc/struct.h b/games/atc/struct.h index 63cfe4b2701..16c480712dd 100644 --- a/games/atc/struct.h +++ b/games/atc/struct.h @@ -1,4 +1,4 @@ -/* $OpenBSD: struct.h,v 1.5 2014/11/16 04:49:48 guenther Exp $ */ +/* $OpenBSD: struct.h,v 1.6 2015/12/31 16:50:29 mestre Exp $ */ /* $NetBSD: struct.h,v 1.3 1995/03/21 15:04:31 cgd Exp $ */ /*- @@ -44,6 +44,8 @@ * For more info on this and all of my stuff, mail edjames@berkeley.edu. */ +#include <limits.h> + typedef struct { int x, y; int dir; /* used only sometimes */ diff --git a/games/atc/update.c b/games/atc/update.c index 0f172c5d737..bfd539fbeec 100644 --- a/games/atc/update.c +++ b/games/atc/update.c @@ -1,4 +1,4 @@ -/* $OpenBSD: update.c,v 1.17 2015/12/15 18:39:50 tb Exp $ */ +/* $OpenBSD: update.c,v 1.18 2015/12/31 16:50:29 mestre Exp $ */ /*- * Copyright (c) 1990, 1993 @@ -41,7 +41,10 @@ * For more info on this and all of my stuff, mail edjames@berkeley.edu. */ -#include "include.h" +#include <stdlib.h> +#include <string.h> + +#include "extern.h" void setseed(const char *seed) |
