Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/games/trek fix redundant decls and nested externs
details: https://anonhg.NetBSD.org/src/rev/3167a34b3aa2
branches: trunk
changeset: 503366:3167a34b3aa2
user: christos <christos%NetBSD.org@localhost>
date: Mon Feb 05 01:12:46 2001 +0000
description:
fix redundant decls and nested externs
diffstat:
games/trek/externs.c | 6 ++----
games/trek/lose.c | 8 ++++----
games/trek/play.c | 7 ++++---
games/trek/win.c | 7 ++++---
4 files changed, 14 insertions(+), 14 deletions(-)
diffs (131 lines):
diff -r 82ec12e8c605 -r 3167a34b3aa2 games/trek/externs.c
--- a/games/trek/externs.c Mon Feb 05 01:10:08 2001 +0000
+++ b/games/trek/externs.c Mon Feb 05 01:12:46 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: externs.c,v 1.6 1999/09/17 17:06:08 jsm Exp $ */
+/* $NetBSD: externs.c,v 1.7 2001/02/05 01:12:46 christos Exp $ */
/*
* Copyright (c) 1980, 1993
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)externs.c 8.1 (Berkeley) 5/31/93";
#else
-__RCSID("$NetBSD: externs.c,v 1.6 1999/09/17 17:06:08 jsm Exp $");
+__RCSID("$NetBSD: externs.c,v 1.7 2001/02/05 01:12:46 christos Exp $");
#endif
#endif /* not lint */
@@ -109,8 +109,6 @@
/* current sector map */
char Sect[NSECTS][NSECTS];
-const struct device Device[NDEV];
-
struct event Event[MAXEVENTS]; /* dynamic event list; one entry per pending event */
struct Ship_struct Ship;
diff -r 82ec12e8c605 -r 3167a34b3aa2 games/trek/lose.c
--- a/games/trek/lose.c Mon Feb 05 01:10:08 2001 +0000
+++ b/games/trek/lose.c Mon Feb 05 01:12:46 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: lose.c,v 1.5 1999/07/21 13:19:11 hubertf Exp $ */
+/* $NetBSD: lose.c,v 1.6 2001/02/05 01:12:46 christos Exp $ */
/*
* Copyright (c) 1980, 1993
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)lose.c 8.1 (Berkeley) 5/31/93";
#else
-__RCSID("$NetBSD: lose.c,v 1.5 1999/07/21 13:19:11 hubertf Exp $");
+__RCSID("$NetBSD: lose.c,v 1.6 2001/02/05 01:12:46 christos Exp $");
#endif
#endif /* not lint */
@@ -56,6 +56,8 @@
** actions which need be taken are taken.
*/
+extern jmp_buf env;
+
const char *const Losemsg[] =
{
"You ran out of time",
@@ -77,8 +79,6 @@
lose(why)
int why;
{
- extern jmp_buf env;
-
Game.killed = 1;
sleep(1);
printf("\n%s\n", Losemsg[why - 1]);
diff -r 82ec12e8c605 -r 3167a34b3aa2 games/trek/play.c
--- a/games/trek/play.c Mon Feb 05 01:10:08 2001 +0000
+++ b/games/trek/play.c Mon Feb 05 01:12:46 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: play.c,v 1.6 1999/09/08 21:45:33 jsm Exp $ */
+/* $NetBSD: play.c,v 1.7 2001/02/05 01:12:46 christos Exp $ */
/*
* Copyright (c) 1980, 1993
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)play.c 8.1 (Berkeley) 5/31/93";
#else
-__RCSID("$NetBSD: play.c,v 1.6 1999/09/08 21:45:33 jsm Exp $");
+__RCSID("$NetBSD: play.c,v 1.7 2001/02/05 01:12:46 christos Exp $");
#endif
#endif /* not lint */
@@ -58,6 +58,8 @@
** on how we are doing after the move.
*/
+extern jmp_buf env;
+
const struct cvntab Comtab[] =
{
{ "abandon", "", abandon, 0 },
@@ -91,7 +93,6 @@
myreset(v)
int v __attribute__((__unused__));
{
- extern jmp_buf env;
longjmp(env, 1);
}
diff -r 82ec12e8c605 -r 3167a34b3aa2 games/trek/win.c
--- a/games/trek/win.c Mon Feb 05 01:10:08 2001 +0000
+++ b/games/trek/win.c Mon Feb 05 01:12:46 2001 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: win.c,v 1.5 1999/07/21 13:19:11 hubertf Exp $ */
+/* $NetBSD: win.c,v 1.6 2001/02/05 01:12:46 christos Exp $ */
/*
* Copyright (c) 1980, 1993
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)win.c 8.1 (Berkeley) 5/31/93";
#else
-__RCSID("$NetBSD: win.c,v 1.5 1999/07/21 13:19:11 hubertf Exp $");
+__RCSID("$NetBSD: win.c,v 1.6 2001/02/05 01:12:46 christos Exp $");
#endif
#endif /* not lint */
@@ -61,12 +61,13 @@
** pretty off the wall.
*/
+extern jmp_buf env;
+
void
win()
{
long s;
const struct cvntab *p = NULL;
- extern jmp_buf env;
sleep(1);
printf("\nCongratulations, you have saved the Federation\n");
Home |
Main Index |
Thread Index |
Old Index