diff options
author | jwise <jwise@NetBSD.org> | 2001-01-04 03:21:16 +0000 |
---|---|---|
committer | jwise <jwise@NetBSD.org> | 2001-01-04 03:21:16 +0000 |
commit | cc53fc319970619b25fdfa3545d62eab5ffa55dd (patch) | |
tree | 47c6c6d1f4a9db7a24fafa1fc3f5e0bd8cc9956e /sail | |
parent | 97e04d4fb9d218f2fb01cc75da027de2f4035be8 (diff) | |
download | bsdgames-darwin-cc53fc319970619b25fdfa3545d62eab5ffa55dd.tar.gz bsdgames-darwin-cc53fc319970619b25fdfa3545d62eab5ffa55dd.tar.zst bsdgames-darwin-cc53fc319970619b25fdfa3545d62eab5ffa55dd.zip |
Rationalize inclusion of header files: cut down on `include everything
everywhere' a little (more to go), and as per KNF, local includes after
system includes.
Diffstat (limited to 'sail')
-rw-r--r-- | sail/assorted.c | 7 | ||||
-rw-r--r-- | sail/dr_1.c | 8 | ||||
-rw-r--r-- | sail/dr_2.c | 7 | ||||
-rw-r--r-- | sail/dr_3.c | 7 | ||||
-rw-r--r-- | sail/dr_4.c | 6 | ||||
-rw-r--r-- | sail/dr_main.c | 8 | ||||
-rw-r--r-- | sail/driver.h | 4 | ||||
-rw-r--r-- | sail/lo_main.c | 10 | ||||
-rw-r--r-- | sail/main.c | 10 | ||||
-rw-r--r-- | sail/misc.c | 7 | ||||
-rw-r--r-- | sail/pl_1.c | 8 | ||||
-rw-r--r-- | sail/pl_3.c | 6 | ||||
-rw-r--r-- | sail/pl_5.c | 5 | ||||
-rw-r--r-- | sail/pl_7.c | 13 | ||||
-rw-r--r-- | sail/pl_main.c | 9 | ||||
-rw-r--r-- | sail/sync.c | 13 |
16 files changed, 61 insertions, 67 deletions
diff --git a/sail/assorted.c b/sail/assorted.c index d2e16a65..1d9d2cbf 100644 --- a/sail/assorted.c +++ b/sail/assorted.c @@ -1,4 +1,4 @@ -/* $NetBSD: assorted.c,v 1.11 2001/01/04 01:53:24 jwise Exp $ */ +/* $NetBSD: assorted.c,v 1.12 2001/01/04 03:21:16 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,14 +38,13 @@ #if 0 static char sccsid[] = "@(#)assorted.c 8.2 (Berkeley) 4/28/95"; #else -__RCSID("$NetBSD: assorted.c,v 1.11 2001/01/04 01:53:24 jwise Exp $"); +__RCSID("$NetBSD: assorted.c,v 1.12 2001/01/04 03:21:16 jwise Exp $"); #endif #endif /* not lint */ -#include "extern.h" #include <stdlib.h> -#include <unistd.h> #include <err.h> +#include "extern.h" void table(int, int, int, struct ship *, struct ship *, int); void Cleansnag(struct ship *, struct ship *, int, int); diff --git a/sail/dr_1.c b/sail/dr_1.c index d63feef2..6106190d 100644 --- a/sail/dr_1.c +++ b/sail/dr_1.c @@ -1,4 +1,4 @@ -/* $NetBSD: dr_1.c,v 1.13 2001/01/04 01:53:24 jwise Exp $ */ +/* $NetBSD: dr_1.c,v 1.14 2001/01/04 03:21:16 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,12 +38,14 @@ #if 0 static char sccsid[] = "@(#)dr_1.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: dr_1.c,v 1.13 2001/01/04 01:53:24 jwise Exp $"); +__RCSID("$NetBSD: dr_1.c,v 1.14 2001/01/04 03:21:16 jwise Exp $"); #endif #endif /* not lint */ -#include "driver.h" +#include <stdio.h> #include <stdlib.h> +#include "extern.h" +#include "driver.h" void unfoul(void); void boardcomp(void); diff --git a/sail/dr_2.c b/sail/dr_2.c index 065902ed..f2787532 100644 --- a/sail/dr_2.c +++ b/sail/dr_2.c @@ -1,4 +1,4 @@ -/* $NetBSD: dr_2.c,v 1.14 2001/01/04 01:53:24 jwise Exp $ */ +/* $NetBSD: dr_2.c,v 1.15 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,12 +38,13 @@ #if 0 static char sccsid[] = "@(#)dr_2.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: dr_2.c,v 1.14 2001/01/04 01:53:24 jwise Exp $"); +__RCSID("$NetBSD: dr_2.c,v 1.15 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ -#include "driver.h" #include <stdlib.h> +#include "extern.h" +#include "driver.h" #define couldwin(f,t) (f->specs->crew2 > t->specs->crew2 * 1.5) diff --git a/sail/dr_3.c b/sail/dr_3.c index 3c8be352..27bf0472 100644 --- a/sail/dr_3.c +++ b/sail/dr_3.c @@ -1,4 +1,4 @@ -/* $NetBSD: dr_3.c,v 1.10 2001/01/04 01:53:24 jwise Exp $ */ +/* $NetBSD: dr_3.c,v 1.11 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,12 +38,13 @@ #if 0 static char sccsid[] = "@(#)dr_3.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: dr_3.c,v 1.10 2001/01/04 01:53:24 jwise Exp $"); +__RCSID("$NetBSD: dr_3.c,v 1.11 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ -#include "driver.h" #include <stdlib.h> +#include "extern.h" +#include "driver.h" void moveall(void); static int stillmoving(int); diff --git a/sail/dr_4.c b/sail/dr_4.c index afd9373c..c29cc80e 100644 --- a/sail/dr_4.c +++ b/sail/dr_4.c @@ -1,4 +1,4 @@ -/* $NetBSD: dr_4.c,v 1.10 2001/01/04 01:53:24 jwise Exp $ */ +/* $NetBSD: dr_4.c,v 1.11 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,12 +38,12 @@ #if 0 static char sccsid[] = "@(#)dr_4.c 8.2 (Berkeley) 4/28/95"; #else -__RCSID("$NetBSD: dr_4.c,v 1.10 2001/01/04 01:53:24 jwise Exp $"); +__RCSID("$NetBSD: dr_4.c,v 1.11 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ -#include "extern.h" #include <stdlib.h> +#include "extern.h" void ungrap(struct ship *, struct ship *); void grap(struct ship *, struct ship *); diff --git a/sail/dr_main.c b/sail/dr_main.c index 0b7db8b4..99144e05 100644 --- a/sail/dr_main.c +++ b/sail/dr_main.c @@ -1,4 +1,4 @@ -/* $NetBSD: dr_main.c,v 1.8 2001/01/04 01:53:24 jwise Exp $ */ +/* $NetBSD: dr_main.c,v 1.9 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,13 +38,15 @@ #if 0 static char sccsid[] = "@(#)dr_main.c 8.2 (Berkeley) 4/16/94"; #else -__RCSID("$NetBSD: dr_main.c,v 1.8 2001/01/04 01:53:24 jwise Exp $"); +__RCSID("$NetBSD: dr_main.c,v 1.9 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ -#include "driver.h" +#include <stdio.h> #include <stdlib.h> #include <unistd.h> +#include "extern.h" +#include "driver.h" int dr_main(void); diff --git a/sail/driver.h b/sail/driver.h index 14385d6c..22f87c9f 100644 --- a/sail/driver.h +++ b/sail/driver.h @@ -1,4 +1,4 @@ -/* $NetBSD: driver.h,v 1.6 1999/09/08 21:17:58 jsm Exp $ */ +/* $NetBSD: driver.h,v 1.7 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -35,6 +35,4 @@ * @(#)driver.h 8.2 (Berkeley) 5/3/95 */ -#include "extern.h" - extern const int dtab[]; diff --git a/sail/lo_main.c b/sail/lo_main.c index f1914ad7..3b91644d 100644 --- a/sail/lo_main.c +++ b/sail/lo_main.c @@ -1,4 +1,4 @@ -/* $NetBSD: lo_main.c,v 1.8 2001/01/01 21:57:38 jwise Exp $ */ +/* $NetBSD: lo_main.c,v 1.9 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,7 +38,7 @@ #if 0 static char sccsid[] = "@(#)lo_main.c 8.2 (Berkeley) 4/28/95"; #else -__RCSID("$NetBSD: lo_main.c,v 1.8 2001/01/01 21:57:38 jwise Exp $"); +__RCSID("$NetBSD: lo_main.c,v 1.9 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ @@ -47,12 +47,14 @@ __RCSID("$NetBSD: lo_main.c,v 1.8 2001/01/01 21:57:38 jwise Exp $"); * * -l force a long listing (print out real usernames) */ -#include <sys/types.h> -#include <stdlib.h> + +#include <stdio.h> #include <pwd.h> #include "extern.h" #include "pathnames.h" +int lo_main(void); + const char *const title[] = { "Admiral", "Commodore", "Captain", "Captain", "Captain", "Captain", "Captain", "Commander", diff --git a/sail/main.c b/sail/main.c index 3dd7e4c5..fff86df2 100644 --- a/sail/main.c +++ b/sail/main.c @@ -1,4 +1,4 @@ -/* $NetBSD: main.c,v 1.17 2001/01/04 01:56:28 jwise Exp $ */ +/* $NetBSD: main.c,v 1.18 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -43,15 +43,15 @@ __COPYRIGHT("@(#) Copyright (c) 1983, 1993\n\ #if 0 static char sccsid[] = "@(#)main.c 8.2 (Berkeley) 4/28/95"; #else -__RCSID("$NetBSD: main.c,v 1.17 2001/01/04 01:56:28 jwise Exp $"); +__RCSID("$NetBSD: main.c,v 1.18 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ -#include "extern.h" #include <fcntl.h> -#include <unistd.h> +#include <stdio.h> #include <stdlib.h> -#include <string.h> +#include <unistd.h> +#include "extern.h" int main(int argc, char **argv) diff --git a/sail/misc.c b/sail/misc.c index 8e3858c5..1e475d53 100644 --- a/sail/misc.c +++ b/sail/misc.c @@ -1,4 +1,4 @@ -/* $NetBSD: misc.c,v 1.8 2001/01/04 02:43:32 jwise Exp $ */ +/* $NetBSD: misc.c,v 1.9 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,12 +38,11 @@ #if 0 static char sccsid[] = "@(#)misc.c 8.2 (Berkeley) 4/28/95"; #else -__RCSID("$NetBSD: misc.c,v 1.8 2001/01/04 02:43:32 jwise Exp $"); +__RCSID("$NetBSD: misc.c,v 1.9 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ -#include <fcntl.h> -#include <stdlib.h> +#include <stdio.h> #include <unistd.h> #include "extern.h" #include "pathnames.h" diff --git a/sail/pl_1.c b/sail/pl_1.c index c73657b1..d003a56a 100644 --- a/sail/pl_1.c +++ b/sail/pl_1.c @@ -1,4 +1,4 @@ -/* $NetBSD: pl_1.c,v 1.10 2001/01/04 02:43:32 jwise Exp $ */ +/* $NetBSD: pl_1.c,v 1.11 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,15 +38,15 @@ #if 0 static char sccsid[] = "@(#)pl_1.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: pl_1.c,v 1.10 2001/01/04 02:43:32 jwise Exp $"); +__RCSID("$NetBSD: pl_1.c,v 1.11 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ -#include "player.h" #include <sys/types.h> #include <sys/wait.h> -#include <stdlib.h> +#include <stdio.h> #include <unistd.h> +#include "player.h" void leave(int); void choke(int); diff --git a/sail/pl_3.c b/sail/pl_3.c index 8e71f220..2cf7c055 100644 --- a/sail/pl_3.c +++ b/sail/pl_3.c @@ -1,4 +1,4 @@ -/* $NetBSD: pl_3.c,v 1.11 2001/01/04 02:43:32 jwise Exp $ */ +/* $NetBSD: pl_3.c,v 1.12 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,12 +38,12 @@ #if 0 static char sccsid[] = "@(#)pl_3.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: pl_3.c,v 1.11 2001/01/04 02:43:32 jwise Exp $"); +__RCSID("$NetBSD: pl_3.c,v 1.12 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ -#include "player.h" #include <stdlib.h> +#include "player.h" void acceptcombat(void); void grapungrap(void); diff --git a/sail/pl_5.c b/sail/pl_5.c index 3d763f3f..369fae93 100644 --- a/sail/pl_5.c +++ b/sail/pl_5.c @@ -1,4 +1,4 @@ -/* $NetBSD: pl_5.c,v 1.9 2001/01/04 02:43:32 jwise Exp $ */ +/* $NetBSD: pl_5.c,v 1.10 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,10 +38,11 @@ #if 0 static char sccsid[] = "@(#)pl_5.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: pl_5.c,v 1.9 2001/01/04 02:43:32 jwise Exp $"); +__RCSID("$NetBSD: pl_5.c,v 1.10 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ +#include <stdio.h> #include "player.h" #define turnfirst(x) (*x == 'r' || *x == 'l') diff --git a/sail/pl_7.c b/sail/pl_7.c index 36cd5347..643045d9 100644 --- a/sail/pl_7.c +++ b/sail/pl_7.c @@ -1,4 +1,4 @@ -/* $NetBSD: pl_7.c,v 1.17 2001/01/04 02:43:33 jwise Exp $ */ +/* $NetBSD: pl_7.c,v 1.18 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,19 +38,14 @@ #if 0 static char sccsid[] = "@(#)pl_7.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: pl_7.c,v 1.17 2001/01/04 02:43:33 jwise Exp $"); +__RCSID("$NetBSD: pl_7.c,v 1.18 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ -#include <sys/ttydefaults.h> -#include "player.h" -#ifdef __STDC__ #include <stdarg.h> -#else -#include <varargs.h> -#endif -#include <stdlib.h> +#include <stdio.h> #include <unistd.h> +#include "player.h" void initscreen(void); void cleanupscreen(void); diff --git a/sail/pl_main.c b/sail/pl_main.c index a818cc33..50cd14ed 100644 --- a/sail/pl_main.c +++ b/sail/pl_main.c @@ -1,4 +1,4 @@ -/* $NetBSD: pl_main.c,v 1.11 2001/01/04 02:43:33 jwise Exp $ */ +/* $NetBSD: pl_main.c,v 1.12 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,15 +38,14 @@ #if 0 static char sccsid[] = "@(#)pl_main.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: pl_main.c,v 1.11 2001/01/04 02:43:33 jwise Exp $"); +__RCSID("$NetBSD: pl_main.c,v 1.12 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ -#include "player.h" -#include <sys/types.h> -#include <sys/wait.h> +#include <stdio.h> #include <stdlib.h> #include <unistd.h> +#include "player.h" int pl_main(void); static void initialize(void); diff --git a/sail/sync.c b/sail/sync.c index 71043d9a..144f25e7 100644 --- a/sail/sync.c +++ b/sail/sync.c @@ -1,4 +1,4 @@ -/* $NetBSD: sync.c,v 1.16 2001/01/04 02:43:33 jwise Exp $ */ +/* $NetBSD: sync.c,v 1.17 2001/01/04 03:21:17 jwise Exp $ */ /* * Copyright (c) 1983, 1993 @@ -38,22 +38,17 @@ #if 0 static char sccsid[] = "@(#)sync.c 8.2 (Berkeley) 4/28/95"; #else -__RCSID("$NetBSD: sync.c,v 1.16 2001/01/04 02:43:33 jwise Exp $"); +__RCSID("$NetBSD: sync.c,v 1.17 2001/01/04 03:21:17 jwise Exp $"); #endif #endif /* not lint */ #include <fcntl.h> #include <errno.h> -#ifdef __STDC__ #include <stdarg.h> -#else -#include <varargs.h> -#endif +#include <stdio.h> #include <stdlib.h> -#include <unistd.h> -#include <sys/types.h> -#include <sys/stat.h> #include <time.h> +#include <unistd.h> #include "extern.h" #include "pathnames.h" |