From bf0917b6aec5e78178d42ce446b4a6edf8e9c984 Mon Sep 17 00:00:00 2001 From: dholland Date: Sun, 24 May 2009 19:18:44 +0000 Subject: [PATCH] ANSIfy function declarations. No object file diffs except for two functions whose K&R declaration didn't fully match the prototype (char vs. int) and the diff of the disassembly of those looks plausible. --- games/trek/abandon.c | 7 +++---- games/trek/attack.c | 9 +++++---- games/trek/autover.c | 6 +++--- games/trek/capture.c | 10 +++++----- games/trek/check_out.c | 7 +++---- games/trek/checkcond.c | 6 +++--- games/trek/compkl.c | 11 ++++++----- games/trek/computer.c | 18 +++++------------- games/trek/damage.c | 11 ++++++----- games/trek/damaged.c | 7 +++---- games/trek/dcrept.c | 7 +++---- games/trek/destruct.c | 7 +++---- games/trek/dock.c | 10 ++++------ games/trek/dumpgame.c | 12 +++++------- games/trek/dumpme.c | 7 +++---- games/trek/dumpssradio.c | 6 +++--- games/trek/getcodi.c | 8 +++----- games/trek/getpar.c | 35 +++++++++++++---------------------- games/trek/help.c | 7 +++---- games/trek/impulse.c | 7 +++---- games/trek/initquad.c | 10 ++++------ games/trek/kill.c | 24 ++++++++++++------------ games/trek/klmove.c | 7 +++---- games/trek/lose.c | 7 +++---- games/trek/lrscan.c | 7 +++---- games/trek/main.c | 8 +++----- games/trek/move.c | 11 ++++------- games/trek/nova.c | 7 +++---- games/trek/out.c | 7 +++---- games/trek/phaser.c | 7 +++---- games/trek/play.c | 9 ++++----- games/trek/ram.c | 7 +++---- games/trek/ranf.c | 10 +++++----- games/trek/rest.c | 7 +++---- games/trek/schedule.c | 29 +++++++++-------------------- games/trek/score.c | 7 ++++--- games/trek/setup.c | 6 +++--- games/trek/setwarp.c | 7 +++---- games/trek/shield.c | 7 +++---- games/trek/snova.c | 7 +++---- games/trek/srscan.c | 7 +++---- games/trek/systemname.c | 8 ++++---- games/trek/torped.c | 10 ++++------ games/trek/visual.c | 7 +++---- games/trek/warp.c | 11 ++++------- games/trek/win.c | 6 +++--- 46 files changed, 187 insertions(+), 251 deletions(-) diff --git a/games/trek/abandon.c b/games/trek/abandon.c index dc1be461fe18..7d67ddb7cbe9 100644 --- a/games/trek/abandon.c +++ b/games/trek/abandon.c @@ -1,4 +1,4 @@ -/* $NetBSD: abandon.c,v 1.7 2007/12/15 19:44:44 perry Exp $ */ +/* $NetBSD: abandon.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)abandon.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: abandon.c,v 1.7 2007/12/15 19:44:44 perry Exp $"); +__RCSID("$NetBSD: abandon.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -68,8 +68,7 @@ __RCSID("$NetBSD: abandon.c,v 1.7 2007/12/15 19:44:44 perry Exp $"); /*ARGSUSED*/ void -abandon(v) - int v __unused; +abandon(int v __unused) { struct quad *q; int i; diff --git a/games/trek/attack.c b/games/trek/attack.c index 8a34b9383de2..a984faeec997 100644 --- a/games/trek/attack.c +++ b/games/trek/attack.c @@ -1,4 +1,4 @@ -/* $NetBSD: attack.c,v 1.5 2003/08/07 09:37:49 agc Exp $ */ +/* $NetBSD: attack.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)attack.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: attack.c,v 1.5 2003/08/07 09:37:49 agc Exp $"); +__RCSID("$NetBSD: attack.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -70,11 +70,12 @@ __RCSID("$NetBSD: attack.c,v 1.5 2003/08/07 09:37:49 agc Exp $"); ** entry for the particular device. ** ** Casualties can also occur. +** +** resting -- set if attack while resting */ void -attack(resting) -int resting; /* set if attack while resting */ +attack(int resting) { int hit, i, l; int maxhit, tothit, shldabsb; diff --git a/games/trek/autover.c b/games/trek/autover.c index 56706a2f56ea..5bdc8d7eedfa 100644 --- a/games/trek/autover.c +++ b/games/trek/autover.c @@ -1,4 +1,4 @@ -/* $NetBSD: autover.c,v 1.5 2003/08/07 09:37:49 agc Exp $ */ +/* $NetBSD: autover.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)autover.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: autover.c,v 1.5 2003/08/07 09:37:49 agc Exp $"); +__RCSID("$NetBSD: autover.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -60,7 +60,7 @@ __RCSID("$NetBSD: autover.c,v 1.5 2003/08/07 09:37:49 agc Exp $"); */ void -autover() +autover(void) { double dist; int course; diff --git a/games/trek/capture.c b/games/trek/capture.c index b7fb0e7543de..fea6ca7c0844 100644 --- a/games/trek/capture.c +++ b/games/trek/capture.c @@ -1,4 +1,4 @@ -/* $NetBSD: capture.c,v 1.7 2007/12/15 19:44:44 perry Exp $ */ +/* $NetBSD: capture.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)capture.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: capture.c,v 1.7 2007/12/15 19:44:44 perry Exp $"); +__RCSID("$NetBSD: capture.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -57,8 +57,7 @@ __RCSID("$NetBSD: capture.c,v 1.7 2007/12/15 19:44:44 perry Exp $"); /*ARGSUSED*/ void -capture(v) - int v __unused; +capture(int v __unused) { int i; struct kling *k; @@ -124,7 +123,8 @@ capture(v) ** Cruddy, just takes one at random. Should ask the captain. */ -struct kling *selectklingon() +struct kling * +selectklingon(void) { int i; diff --git a/games/trek/check_out.c b/games/trek/check_out.c index 10e731fa6621..d273b82b22a1 100644 --- a/games/trek/check_out.c +++ b/games/trek/check_out.c @@ -1,4 +1,4 @@ -/* $NetBSD: check_out.c,v 1.5 2003/08/07 09:37:50 agc Exp $ */ +/* $NetBSD: check_out.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)check_out.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: check_out.c,v 1.5 2003/08/07 09:37:50 agc Exp $"); +__RCSID("$NetBSD: check_out.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -53,8 +53,7 @@ __RCSID("$NetBSD: check_out.c,v 1.5 2003/08/07 09:37:50 agc Exp $"); */ int -check_out(device) -int device; +check_out(int device) { int dev; diff --git a/games/trek/checkcond.c b/games/trek/checkcond.c index 9a969d12c06f..560138a17304 100644 --- a/games/trek/checkcond.c +++ b/games/trek/checkcond.c @@ -1,4 +1,4 @@ -/* $NetBSD: checkcond.c,v 1.5 2003/08/07 09:37:50 agc Exp $ */ +/* $NetBSD: checkcond.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)checkcond.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: checkcond.c,v 1.5 2003/08/07 09:37:50 agc Exp $"); +__RCSID("$NetBSD: checkcond.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -66,7 +66,7 @@ __RCSID("$NetBSD: checkcond.c,v 1.5 2003/08/07 09:37:50 agc Exp $"); */ void -checkcond() +checkcond(void) { /* see if we are still alive and well */ if (Ship.reserves < 0.0) diff --git a/games/trek/compkl.c b/games/trek/compkl.c index 85a948535032..1850d78e7740 100644 --- a/games/trek/compkl.c +++ b/games/trek/compkl.c @@ -1,4 +1,4 @@ -/* $NetBSD: compkl.c,v 1.6 2004/01/27 20:30:30 jsm Exp $ */ +/* $NetBSD: compkl.c,v 1.7 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)compkl.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: compkl.c,v 1.6 2004/01/27 20:30:30 jsm Exp $"); +__RCSID("$NetBSD: compkl.c,v 1.7 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -50,13 +50,14 @@ __RCSID("$NetBSD: compkl.c,v 1.6 2004/01/27 20:30:30 jsm Exp $"); ** ** This routine is used every time the Enterprise or the Klingons ** move. +** +** f -- set if new quadrant */ static void sortkl(void); void -compkldist(f) -int f; /* set if new quadrant */ +compkldist(int f) { int i, dx, dy; double d; @@ -98,7 +99,7 @@ int f; /* set if new quadrant */ */ static void -sortkl() +sortkl(void) { struct kling t; int f, i, m; diff --git a/games/trek/computer.c b/games/trek/computer.c index a470cc479e04..62a6c73d1b9a 100644 --- a/games/trek/computer.c +++ b/games/trek/computer.c @@ -1,4 +1,4 @@ -/* $NetBSD: computer.c,v 1.11 2007/12/15 19:44:44 perry Exp $ */ +/* $NetBSD: computer.c,v 1.12 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)computer.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: computer.c,v 1.11 2007/12/15 19:44:44 perry Exp $"); +__RCSID("$NetBSD: computer.c,v 1.12 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -109,8 +109,7 @@ static void prkalc(int, double); /*ARGSUSED*/ void -computer(v) - int v __unused; +computer(int v __unused) { int ix, iy; int i, j; @@ -317,12 +316,7 @@ computer(v) */ static int -kalc(tqx, tqy, tsx, tsy, dist) -int tqx; -int tqy; -int tsx; -int tsy; -double *dist; +kalc(int tqx, int tqy, int tsx, int tsy, double *dist) { double dx, dy; double quadsize; @@ -347,9 +341,7 @@ double *dist; } static void -prkalc(course, dist) -int course; -double dist; +prkalc(int course, double dist) { printf(": course %d dist %.3f\n", course, dist); } diff --git a/games/trek/damage.c b/games/trek/damage.c index 979b23033400..d928883f5663 100644 --- a/games/trek/damage.c +++ b/games/trek/damage.c @@ -1,4 +1,4 @@ -/* $NetBSD: damage.c,v 1.6 2003/08/07 09:37:50 agc Exp $ */ +/* $NetBSD: damage.c,v 1.7 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)damage.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: damage.c,v 1.6 2003/08/07 09:37:50 agc Exp $"); +__RCSID("$NetBSD: damage.c,v 1.7 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -52,12 +52,13 @@ __RCSID("$NetBSD: damage.c,v 1.6 2003/08/07 09:37:50 agc Exp $"); ** ** Note that the repair of the device occurs on a DATE, meaning ** that the dock() and undock() have to reschedule the event. +** +** dev1 -- device index +** dam -- time to repair */ void -damage(dev1, dam) -int dev1; /* device index */ -double dam; /* time to repair */ +damage(int dev1, double dam) { int i; struct event *e; diff --git a/games/trek/damaged.c b/games/trek/damaged.c index 8e6c08a17250..ed6c41996484 100644 --- a/games/trek/damaged.c +++ b/games/trek/damaged.c @@ -1,4 +1,4 @@ -/* $NetBSD: damaged.c,v 1.5 2003/08/07 09:37:50 agc Exp $ */ +/* $NetBSD: damaged.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)damaged.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: damaged.c,v 1.5 2003/08/07 09:37:50 agc Exp $"); +__RCSID("$NetBSD: damaged.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -48,8 +48,7 @@ __RCSID("$NetBSD: damaged.c,v 1.5 2003/08/07 09:37:50 agc Exp $"); */ int -damaged(dev) -int dev; +damaged(int dev) { int d; struct event *e; diff --git a/games/trek/dcrept.c b/games/trek/dcrept.c index d6bbd85218f3..e198182329d2 100644 --- a/games/trek/dcrept.c +++ b/games/trek/dcrept.c @@ -1,4 +1,4 @@ -/* $NetBSD: dcrept.c,v 1.7 2007/12/15 19:44:44 perry Exp $ */ +/* $NetBSD: dcrept.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)dcrept.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: dcrept.c,v 1.7 2007/12/15 19:44:44 perry Exp $"); +__RCSID("$NetBSD: dcrept.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -55,8 +55,7 @@ __RCSID("$NetBSD: dcrept.c,v 1.7 2007/12/15 19:44:44 perry Exp $"); /*ARGSUSED*/ void -dcrept(v) - int v __unused; +dcrept(int v __unused) { int i, f; double x; diff --git a/games/trek/destruct.c b/games/trek/destruct.c index 6f22517b1722..0ce2d0d33d03 100644 --- a/games/trek/destruct.c +++ b/games/trek/destruct.c @@ -1,4 +1,4 @@ -/* $NetBSD: destruct.c,v 1.8 2007/12/15 19:44:44 perry Exp $ */ +/* $NetBSD: destruct.c,v 1.9 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)destruct.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: destruct.c,v 1.8 2007/12/15 19:44:44 perry Exp $"); +__RCSID("$NetBSD: destruct.c,v 1.9 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -66,8 +66,7 @@ __RCSID("$NetBSD: destruct.c,v 1.8 2007/12/15 19:44:44 perry Exp $"); /*ARGSUSED*/ void -destruct(v) - int v __unused; +destruct(int v __unused) { char checkpass[15]; int i, j; diff --git a/games/trek/dock.c b/games/trek/dock.c index b9ba43e18869..fd50faad3f82 100644 --- a/games/trek/dock.c +++ b/games/trek/dock.c @@ -1,4 +1,4 @@ -/* $NetBSD: dock.c,v 1.7 2007/12/15 19:44:44 perry Exp $ */ +/* $NetBSD: dock.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)dock.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: dock.c,v 1.7 2007/12/15 19:44:44 perry Exp $"); +__RCSID("$NetBSD: dock.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -58,8 +58,7 @@ __RCSID("$NetBSD: dock.c,v 1.7 2007/12/15 19:44:44 perry Exp $"); /*ARGSUSED*/ void -dock(v) - int v __unused; +dock(int v __unused) { int i, j; int ok; @@ -132,8 +131,7 @@ dock(v) /*ARGSUSED*/ void -undock(v) - int v __unused; +undock(int v __unused) { struct event *e; int i; diff --git a/games/trek/dumpgame.c b/games/trek/dumpgame.c index 83c5e6ffa853..2d5527b62447 100644 --- a/games/trek/dumpgame.c +++ b/games/trek/dumpgame.c @@ -1,4 +1,4 @@ -/* $NetBSD: dumpgame.c,v 1.11 2007/12/15 19:44:44 perry Exp $ */ +/* $NetBSD: dumpgame.c,v 1.12 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)dumpgame.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: dumpgame.c,v 1.11 2007/12/15 19:44:44 perry Exp $"); +__RCSID("$NetBSD: dumpgame.c,v 1.12 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -82,8 +82,7 @@ struct dump Dump_template[] = /*ARGSUSED*/ void -dumpgame(v) - int v __unused; +dumpgame(int v __unused) { int version; int fd; @@ -121,7 +120,7 @@ dumpgame(v) */ int -restartgame() +restartgame(void) { int fd; int version; @@ -152,8 +151,7 @@ restartgame() */ static int -readdump(fd1) -int fd1; +readdump(int fd1) { int fd; struct dump *d; diff --git a/games/trek/dumpme.c b/games/trek/dumpme.c index c06cf12b5953..e777dfe18b93 100644 --- a/games/trek/dumpme.c +++ b/games/trek/dumpme.c @@ -1,4 +1,4 @@ -/* $NetBSD: dumpme.c,v 1.5 2003/08/07 09:37:51 agc Exp $ */ +/* $NetBSD: dumpme.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)dumpme.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: dumpme.c,v 1.5 2003/08/07 09:37:51 agc Exp $"); +__RCSID("$NetBSD: dumpme.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -54,8 +54,7 @@ __RCSID("$NetBSD: dumpme.c,v 1.5 2003/08/07 09:37:51 agc Exp $"); */ void -dumpme(flag) -int flag; +dumpme(int flag) { int f; double x; diff --git a/games/trek/dumpssradio.c b/games/trek/dumpssradio.c index 8062322c5405..99ad4aca2e6b 100644 --- a/games/trek/dumpssradio.c +++ b/games/trek/dumpssradio.c @@ -1,4 +1,4 @@ -/* $NetBSD: dumpssradio.c,v 1.5 2003/08/07 09:37:51 agc Exp $ */ +/* $NetBSD: dumpssradio.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)dumpssradio.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: dumpssradio.c,v 1.5 2003/08/07 09:37:51 agc Exp $"); +__RCSID("$NetBSD: dumpssradio.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -46,7 +46,7 @@ __RCSID("$NetBSD: dumpssradio.c,v 1.5 2003/08/07 09:37:51 agc Exp $"); **/ int -dumpssradio() +dumpssradio(void) { struct event *e; int j; diff --git a/games/trek/getcodi.c b/games/trek/getcodi.c index f6af1db49d08..e8523462f79e 100644 --- a/games/trek/getcodi.c +++ b/games/trek/getcodi.c @@ -1,4 +1,4 @@ -/* $NetBSD: getcodi.c,v 1.5 2003/08/07 09:37:51 agc Exp $ */ +/* $NetBSD: getcodi.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)getcodi.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: getcodi.c,v 1.5 2003/08/07 09:37:51 agc Exp $"); +__RCSID("$NetBSD: getcodi.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -52,9 +52,7 @@ __RCSID("$NetBSD: getcodi.c,v 1.5 2003/08/07 09:37:51 agc Exp $"); */ int -getcodi(co, di) -int *co; -double *di; +getcodi(int *co, double *di) { *co = getintpar("Course"); diff --git a/games/trek/getpar.c b/games/trek/getpar.c index 5d5683231892..b51a209d762c 100644 --- a/games/trek/getpar.c +++ b/games/trek/getpar.c @@ -1,4 +1,4 @@ -/* $NetBSD: getpar.c,v 1.12 2004/01/27 20:30:31 jsm Exp $ */ +/* $NetBSD: getpar.c,v 1.13 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)getpar.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: getpar.c,v 1.12 2004/01/27 20:30:31 jsm Exp $"); +__RCSID("$NetBSD: getpar.c,v 1.13 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -51,8 +51,7 @@ static int testterm(void); **/ int -getintpar(s) - const char *s; +getintpar(const char *s) { int i; int n; @@ -75,8 +74,8 @@ getintpar(s) ** get floating parameter **/ -double getfltpar(s) - const char *s; +double +getfltpar(const char *s) { int i; double d; @@ -107,8 +106,7 @@ const struct cvntab Yntab[] = }; int -getynpar(s) - const char *s; +getynpar(const char *s) { const struct cvntab *r; @@ -121,9 +119,8 @@ getynpar(s) ** get coded parameter **/ -const struct cvntab *getcodpar(s, tab) - const char *s; - const struct cvntab tab[]; +const struct cvntab * +getcodpar(const char *s, const struct cvntab tab[]) { char input[100]; const struct cvntab *r; @@ -200,11 +197,7 @@ const struct cvntab *getcodpar(s, tab) **/ void -getstrpar(s, r, l, t) - const char *s; - char *r; - int l; - const char *t; +getstrpar(const char *s, char *r, int l, const char *t) { int i; char format[20]; @@ -234,7 +227,7 @@ getstrpar(s, r, l, t) **/ int -testnl() +testnl(void) { char c; @@ -256,8 +249,7 @@ testnl() **/ void -skiptonl(c) -int c; +skiptonl(int c) { while (c != '\n') if (!(c = cgetc(0))) @@ -272,7 +264,7 @@ int c; **/ static int -testterm() +testterm(void) { char c; @@ -295,8 +287,7 @@ testterm() */ int -readdelim(d) -char d; +readdelim(int d) { char c; diff --git a/games/trek/help.c b/games/trek/help.c index 5cf90d5b6ec6..2d6447a1b768 100644 --- a/games/trek/help.c +++ b/games/trek/help.c @@ -1,4 +1,4 @@ -/* $NetBSD: help.c,v 1.9 2009/03/31 18:48:16 christos Exp $ */ +/* $NetBSD: help.c,v 1.10 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)help.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: help.c,v 1.9 2009/03/31 18:48:16 christos Exp $"); +__RCSID("$NetBSD: help.c,v 1.10 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -69,8 +69,7 @@ const char *const Cntvect[3] = /*ARGSUSED*/ void -help(v) - int v __unused; +help(int v __unused) { int i; double dist, x; diff --git a/games/trek/impulse.c b/games/trek/impulse.c index 50ceeca86771..50be22b9496f 100644 --- a/games/trek/impulse.c +++ b/games/trek/impulse.c @@ -1,4 +1,4 @@ -/* $NetBSD: impulse.c,v 1.7 2007/12/15 19:44:44 perry Exp $ */ +/* $NetBSD: impulse.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)impulse.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: impulse.c,v 1.7 2007/12/15 19:44:44 perry Exp $"); +__RCSID("$NetBSD: impulse.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -48,8 +48,7 @@ __RCSID("$NetBSD: impulse.c,v 1.7 2007/12/15 19:44:44 perry Exp $"); /*ARGSUSED*/ void -impulse(v) - int v __unused; +impulse(int v __unused) { int course; int power; diff --git a/games/trek/initquad.c b/games/trek/initquad.c index bb75ee962d3d..72de8d6390f7 100644 --- a/games/trek/initquad.c +++ b/games/trek/initquad.c @@ -1,4 +1,4 @@ -/* $NetBSD: initquad.c,v 1.5 2003/08/07 09:37:52 agc Exp $ */ +/* $NetBSD: initquad.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)initquad.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: initquad.c,v 1.5 2003/08/07 09:37:52 agc Exp $"); +__RCSID("$NetBSD: initquad.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -59,8 +59,7 @@ __RCSID("$NetBSD: initquad.c,v 1.5 2003/08/07 09:37:52 agc Exp $"); */ void -initquad(f) -int f; +initquad(int f) { int i, j; int rx, ry; @@ -142,8 +141,7 @@ int f; void -sector(x, y) -int *x, *y; +sector(int *x, int *y) { int i, j; diff --git a/games/trek/kill.c b/games/trek/kill.c index 1d8f61300346..6165cab9b31f 100644 --- a/games/trek/kill.c +++ b/games/trek/kill.c @@ -1,4 +1,4 @@ -/* $NetBSD: kill.c,v 1.8 2009/03/31 18:48:16 christos Exp $ */ +/* $NetBSD: kill.c,v 1.9 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)kill.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: kill.c,v 1.8 2009/03/31 18:48:16 christos Exp $"); +__RCSID("$NetBSD: kill.c,v 1.9 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -59,8 +59,7 @@ __RCSID("$NetBSD: kill.c,v 1.8 2009/03/31 18:48:16 christos Exp $"); */ void -killk(ix, iy) -int ix, iy; +killk(int ix, int iy) { int i; @@ -100,8 +99,7 @@ int ix, iy; */ void -killb(qx, qy) -int qx, qy; +killb(int qx, int qy) { struct quad *q; struct xy *b; @@ -146,12 +144,13 @@ int qx, qy; /** ** kill an inhabited starsystem + ** + ** x, y are quad coords if f == 0, else sector coords + ** f != 0 -- this quad; f < 0 -- Enterprise's fault **/ void -kills(x, y, f) -int x, y; /* quad coords if f == 0, else sector coords */ -int f; /* f != 0 -- this quad; f < 0 -- Enterprise's fault */ +kills(int x, int y, int f) { struct quad *q; struct event *e; @@ -190,12 +189,13 @@ int f; /* f != 0 -- this quad; f < 0 -- Enterprise's fault */ /** ** "kill" a distress call + ** + ** x, y are quadrant coordinates + ** f is set if user is to be informed **/ void -killd(x, y, f) -int x, y; /* quadrant coordinates */ -int f; /* set if user is to be informed */ +killd(int x, int y, int f) { struct event *e; int i; diff --git a/games/trek/klmove.c b/games/trek/klmove.c index 0ab26fec64e0..17d636c99918 100644 --- a/games/trek/klmove.c +++ b/games/trek/klmove.c @@ -1,4 +1,4 @@ -/* $NetBSD: klmove.c,v 1.5 2003/08/07 09:37:52 agc Exp $ */ +/* $NetBSD: klmove.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)klmove.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: klmove.c,v 1.5 2003/08/07 09:37:52 agc Exp $"); +__RCSID("$NetBSD: klmove.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -65,8 +65,7 @@ __RCSID("$NetBSD: klmove.c,v 1.5 2003/08/07 09:37:52 agc Exp $"); */ void -klmove(fl) -int fl; +klmove(int fl) { int n; struct kling *k; diff --git a/games/trek/lose.c b/games/trek/lose.c index efb89fd9ec06..eae32a916b57 100644 --- a/games/trek/lose.c +++ b/games/trek/lose.c @@ -1,4 +1,4 @@ -/* $NetBSD: lose.c,v 1.7 2003/08/07 09:37:52 agc Exp $ */ +/* $NetBSD: lose.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)lose.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: lose.c,v 1.7 2003/08/07 09:37:52 agc Exp $"); +__RCSID("$NetBSD: lose.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -72,8 +72,7 @@ const char *const Losemsg[] = }; void -lose(why) -int why; +lose(int why) { Game.killed = 1; sleep(1); diff --git a/games/trek/lrscan.c b/games/trek/lrscan.c index 3e18baeb3d7c..041387127b07 100644 --- a/games/trek/lrscan.c +++ b/games/trek/lrscan.c @@ -1,4 +1,4 @@ -/* $NetBSD: lrscan.c,v 1.7 2007/12/15 19:44:44 perry Exp $ */ +/* $NetBSD: lrscan.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)lrscan.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: lrscan.c,v 1.7 2007/12/15 19:44:44 perry Exp $"); +__RCSID("$NetBSD: lrscan.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -55,8 +55,7 @@ __RCSID("$NetBSD: lrscan.c,v 1.7 2007/12/15 19:44:44 perry Exp $"); /*ARGSUSED*/ void -lrscan(v) - int v __unused; +lrscan(int v __unused) { int i, j; struct quad *q; diff --git a/games/trek/main.c b/games/trek/main.c index dc987ef9e0db..c0456d9c028c 100644 --- a/games/trek/main.c +++ b/games/trek/main.c @@ -1,4 +1,4 @@ -/* $NetBSD: main.c,v 1.13 2008/07/20 01:03:22 lukem Exp $ */ +/* $NetBSD: main.c,v 1.14 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -39,7 +39,7 @@ __COPYRIGHT("@(#) Copyright (c) 1980, 1993\ #if 0 static char sccsid[] = "@(#)main.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: main.c,v 1.13 2008/07/20 01:03:22 lukem Exp $"); +__RCSID("$NetBSD: main.c,v 1.14 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -160,9 +160,7 @@ jmp_buf env; int main(int, char **); int -main(argc, argv) -int argc; -char **argv; +main(int argc, char **argv) { time_t curtime; long vect; diff --git a/games/trek/move.c b/games/trek/move.c index d1941b53e738..912be9d3b772 100644 --- a/games/trek/move.c +++ b/games/trek/move.c @@ -1,4 +1,4 @@ -/* $NetBSD: move.c,v 1.6 2003/08/07 09:37:52 agc Exp $ */ +/* $NetBSD: move.c,v 1.7 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)move.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: move.c,v 1.6 2003/08/07 09:37:52 agc Exp $"); +__RCSID("$NetBSD: move.c,v 1.7 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -77,11 +77,8 @@ __RCSID("$NetBSD: move.c,v 1.6 2003/08/07 09:37:52 agc Exp $"); ** Uses trace flag 4. */ -double move(ramflag, course, time, speed) -int ramflag; -int course; -double time; -double speed; +double +move(int ramflag, int course, double time, double speed) { double angle; double x, y, dx, dy; diff --git a/games/trek/nova.c b/games/trek/nova.c index 7c5a87671f79..8a417d30841a 100644 --- a/games/trek/nova.c +++ b/games/trek/nova.c @@ -1,4 +1,4 @@ -/* $NetBSD: nova.c,v 1.6 2003/08/07 09:37:53 agc Exp $ */ +/* $NetBSD: nova.c,v 1.7 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)nova.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: nova.c,v 1.6 2003/08/07 09:37:53 agc Exp $"); +__RCSID("$NetBSD: nova.c,v 1.7 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -56,8 +56,7 @@ __RCSID("$NetBSD: nova.c,v 1.6 2003/08/07 09:37:53 agc Exp $"); */ void -nova(x, y) -int x, y; +nova(int x, int y) { int i, j; int se; diff --git a/games/trek/out.c b/games/trek/out.c index 550c2c26e483..7522b870e769 100644 --- a/games/trek/out.c +++ b/games/trek/out.c @@ -1,4 +1,4 @@ -/* $NetBSD: out.c,v 1.7 2003/08/07 09:37:53 agc Exp $ */ +/* $NetBSD: out.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)out.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: out.c,v 1.7 2003/08/07 09:37:53 agc Exp $"); +__RCSID("$NetBSD: out.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -47,8 +47,7 @@ __RCSID("$NetBSD: out.c,v 1.7 2003/08/07 09:37:53 agc Exp $"); */ void -out(dev) -int dev; +out(int dev) { const struct device *d; diff --git a/games/trek/phaser.c b/games/trek/phaser.c index 4fbd784ec4b9..7ac3b8b6341f 100644 --- a/games/trek/phaser.c +++ b/games/trek/phaser.c @@ -1,4 +1,4 @@ -/* $NetBSD: phaser.c,v 1.10 2007/12/15 19:44:44 perry Exp $ */ +/* $NetBSD: phaser.c,v 1.11 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)phaser.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: phaser.c,v 1.10 2007/12/15 19:44:44 perry Exp $"); +__RCSID("$NetBSD: phaser.c,v 1.11 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -94,8 +94,7 @@ struct banks /*ARGSUSED*/ void -phaser(v) - int v __unused; +phaser(int v __unused) { int i; int j; diff --git a/games/trek/play.c b/games/trek/play.c index ad9cf92787b5..9553ee8ba8fa 100644 --- a/games/trek/play.c +++ b/games/trek/play.c @@ -1,4 +1,4 @@ -/* $NetBSD: play.c,v 1.9 2007/12/15 19:44:45 perry Exp $ */ +/* $NetBSD: play.c,v 1.10 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)play.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: play.c,v 1.9 2007/12/15 19:44:45 perry Exp $"); +__RCSID("$NetBSD: play.c,v 1.10 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -86,15 +86,14 @@ const struct cvntab Comtab[] = /*ARGSUSED*/ void -myreset(v) - int v __unused; +myreset(int v __unused) { longjmp(env, 1); } void -play() +play(void) { const struct cvntab *r; diff --git a/games/trek/ram.c b/games/trek/ram.c index 008c6916e5f3..7e6c87817a4c 100644 --- a/games/trek/ram.c +++ b/games/trek/ram.c @@ -1,4 +1,4 @@ -/* $NetBSD: ram.c,v 1.5 2003/08/07 09:37:53 agc Exp $ */ +/* $NetBSD: ram.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)ram.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: ram.c,v 1.5 2003/08/07 09:37:53 agc Exp $"); +__RCSID("$NetBSD: ram.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -54,8 +54,7 @@ __RCSID("$NetBSD: ram.c,v 1.5 2003/08/07 09:37:53 agc Exp $"); */ void -ram(ix, iy) -int ix, iy; +ram(int ix, int iy) { int i; char c; diff --git a/games/trek/ranf.c b/games/trek/ranf.c index 24e3328f77f9..2b553d9b6b59 100644 --- a/games/trek/ranf.c +++ b/games/trek/ranf.c @@ -1,4 +1,4 @@ -/* $NetBSD: ranf.c,v 1.5 2003/08/07 09:37:53 agc Exp $ */ +/* $NetBSD: ranf.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)ranf.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: ranf.c,v 1.5 2003/08/07 09:37:53 agc Exp $"); +__RCSID("$NetBSD: ranf.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -43,8 +43,7 @@ __RCSID("$NetBSD: ranf.c,v 1.5 2003/08/07 09:37:53 agc Exp $"); #include "trek.h" int -ranf(max) -int max; +ranf(int max) { int t; @@ -55,7 +54,8 @@ int max; } -double franf() +double +franf(void) { double t; t = rand() & 077777; diff --git a/games/trek/rest.c b/games/trek/rest.c index d4478c6f661c..1478e9b475a7 100644 --- a/games/trek/rest.c +++ b/games/trek/rest.c @@ -1,4 +1,4 @@ -/* $NetBSD: rest.c,v 1.7 2007/12/15 19:44:45 perry Exp $ */ +/* $NetBSD: rest.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)rest.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: rest.c,v 1.7 2007/12/15 19:44:45 perry Exp $"); +__RCSID("$NetBSD: rest.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -58,8 +58,7 @@ __RCSID("$NetBSD: rest.c,v 1.7 2007/12/15 19:44:45 perry Exp $"); /*ARGSUSED*/ void -rest(v) - int v __unused; +rest(int v __unused) { double t; int percent; diff --git a/games/trek/schedule.c b/games/trek/schedule.c index 455c5e0633a9..76bf375d90a9 100644 --- a/games/trek/schedule.c +++ b/games/trek/schedule.c @@ -1,4 +1,4 @@ -/* $NetBSD: schedule.c,v 1.7 2009/03/31 18:48:16 christos Exp $ */ +/* $NetBSD: schedule.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)schedule.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: schedule.c,v 1.7 2009/03/31 18:48:16 christos Exp $"); +__RCSID("$NetBSD: schedule.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -54,11 +54,8 @@ __RCSID("$NetBSD: schedule.c,v 1.7 2009/03/31 18:48:16 christos Exp $"); ** The address of the slot is returned. */ -struct event *schedule(type, offset, x, y, z) -int type; -double offset; -char x, y; -char z; +struct event * +schedule(int type, double offset, int x, int y, int z) { struct event *e; int i; @@ -96,9 +93,7 @@ char z; */ void -reschedule(e1, offset) -struct event *e1; -double offset; +reschedule(struct event *e1, double offset) { double date; struct event *e; @@ -123,8 +118,7 @@ double offset; */ void -unschedule(e1) -struct event *e1; +unschedule(struct event *e1) { struct event *e; @@ -149,10 +143,8 @@ struct event *e1; ** figure. */ -struct event *xsched(ev1, factor, x, y, z) -int ev1; -int factor; -int x, y, z; +struct event * +xsched(int ev1, int factor, int x, int y, int z) { int ev; @@ -169,10 +161,7 @@ int x, y, z; */ void -xresched(e1, ev1, factor) -struct event *e1; -int ev1; -int factor; +xresched(struct event *e1, int ev1, int factor) { int ev; struct event *e; diff --git a/games/trek/score.c b/games/trek/score.c index 9deb214c7f83..553f0a2caab6 100644 --- a/games/trek/score.c +++ b/games/trek/score.c @@ -1,4 +1,4 @@ -/* $NetBSD: score.c,v 1.5 2003/08/07 09:37:54 agc Exp $ */ +/* $NetBSD: score.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)score.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: score.c,v 1.5 2003/08/07 09:37:54 agc Exp $"); +__RCSID("$NetBSD: score.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -46,7 +46,8 @@ __RCSID("$NetBSD: score.c,v 1.5 2003/08/07 09:37:54 agc Exp $"); ** PRINT OUT THE CURRENT SCORE */ -long score() +long +score(void) { int u; int t; diff --git a/games/trek/setup.c b/games/trek/setup.c index 3a9f93f2df17..715a38896ab4 100644 --- a/games/trek/setup.c +++ b/games/trek/setup.c @@ -1,4 +1,4 @@ -/* $NetBSD: setup.c,v 1.10 2009/03/31 18:48:16 christos Exp $ */ +/* $NetBSD: setup.c,v 1.11 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)setup.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: setup.c,v 1.10 2009/03/31 18:48:16 christos Exp $"); +__RCSID("$NetBSD: setup.c,v 1.11 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -80,7 +80,7 @@ const struct cvntab Skitab[] = }; void -setup() +setup(void) { const struct cvntab *r; int i, j; diff --git a/games/trek/setwarp.c b/games/trek/setwarp.c index 17f874501350..b0ab045399c2 100644 --- a/games/trek/setwarp.c +++ b/games/trek/setwarp.c @@ -1,4 +1,4 @@ -/* $NetBSD: setwarp.c,v 1.7 2007/12/15 19:44:45 perry Exp $ */ +/* $NetBSD: setwarp.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)setwarp.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: setwarp.c,v 1.7 2007/12/15 19:44:45 perry Exp $"); +__RCSID("$NetBSD: setwarp.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -51,8 +51,7 @@ __RCSID("$NetBSD: setwarp.c,v 1.7 2007/12/15 19:44:45 perry Exp $"); /*ARGSUSED*/ void -setwarp(v) - int v __unused; +setwarp(int v __unused) { double warpfac; diff --git a/games/trek/shield.c b/games/trek/shield.c index b49e037acbe3..c74444b00c9b 100644 --- a/games/trek/shield.c +++ b/games/trek/shield.c @@ -1,4 +1,4 @@ -/* $NetBSD: shield.c,v 1.8 2003/08/07 09:37:54 agc Exp $ */ +/* $NetBSD: shield.c,v 1.9 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)shield.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: shield.c,v 1.8 2003/08/07 09:37:54 agc Exp $"); +__RCSID("$NetBSD: shield.c,v 1.9 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -67,8 +67,7 @@ const struct cvntab Udtab[] = }; void -shield(f) -int f; +shield(int f) { int i; const struct cvntab *r; diff --git a/games/trek/snova.c b/games/trek/snova.c index ef7a42d1c3e1..073f10def593 100644 --- a/games/trek/snova.c +++ b/games/trek/snova.c @@ -1,4 +1,4 @@ -/* $NetBSD: snova.c,v 1.5 2003/08/07 09:37:54 agc Exp $ */ +/* $NetBSD: snova.c,v 1.6 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)snova.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: snova.c,v 1.5 2003/08/07 09:37:54 agc Exp $"); +__RCSID("$NetBSD: snova.c,v 1.6 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -64,8 +64,7 @@ __RCSID("$NetBSD: snova.c,v 1.5 2003/08/07 09:37:54 agc Exp $"); */ void -snova(x, y) -int x, y; +snova(int x, int y) { int qx, qy; int ix, iy = 0; diff --git a/games/trek/srscan.c b/games/trek/srscan.c index 1ce750a6726c..a1f45f79c83b 100644 --- a/games/trek/srscan.c +++ b/games/trek/srscan.c @@ -1,4 +1,4 @@ -/* $NetBSD: srscan.c,v 1.6 2003/08/07 09:37:54 agc Exp $ */ +/* $NetBSD: srscan.c,v 1.7 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)srscan.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: srscan.c,v 1.6 2003/08/07 09:37:54 agc Exp $"); +__RCSID("$NetBSD: srscan.c,v 1.7 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -66,8 +66,7 @@ const char *const Color[4] = }; void -srscan(f) -int f; +srscan(int f) { int i, j; int statinfo; diff --git a/games/trek/systemname.c b/games/trek/systemname.c index 64193f50b1ef..b5e3ad761802 100644 --- a/games/trek/systemname.c +++ b/games/trek/systemname.c @@ -1,4 +1,4 @@ -/* $NetBSD: systemname.c,v 1.6 2003/08/07 09:37:54 agc Exp $ */ +/* $NetBSD: systemname.c,v 1.7 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)systemname.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: systemname.c,v 1.6 2003/08/07 09:37:54 agc Exp $"); +__RCSID("$NetBSD: systemname.c,v 1.7 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -51,8 +51,8 @@ __RCSID("$NetBSD: systemname.c,v 1.6 2003/08/07 09:37:54 agc Exp $"); ** starsystems, etc. */ -const char *systemname(q1) - const struct quad *q1; +const char * +systemname(const struct quad *q1) { const struct quad *q; int i; diff --git a/games/trek/torped.c b/games/trek/torped.c index a0e6be7b2b32..3e1b38537123 100644 --- a/games/trek/torped.c +++ b/games/trek/torped.c @@ -1,4 +1,4 @@ -/* $NetBSD: torped.c,v 1.9 2007/12/15 19:44:45 perry Exp $ */ +/* $NetBSD: torped.c,v 1.10 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)torped.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: torped.c,v 1.9 2007/12/15 19:44:45 perry Exp $"); +__RCSID("$NetBSD: torped.c,v 1.10 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -67,8 +67,7 @@ static int randcourse(int); /*ARGSUSED*/ void -torped(v) - int v __unused; +torped(int v __unused) { int ix, iy; double x, y, dx, dy; @@ -230,8 +229,7 @@ torped(v) */ static int -randcourse(n) -int n; +randcourse(int n) { double r; int d; diff --git a/games/trek/visual.c b/games/trek/visual.c index 4137ec6150b9..258a31942cd4 100644 --- a/games/trek/visual.c +++ b/games/trek/visual.c @@ -1,4 +1,4 @@ -/* $NetBSD: visual.c,v 1.7 2007/12/15 19:44:45 perry Exp $ */ +/* $NetBSD: visual.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)visual.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: visual.c,v 1.7 2007/12/15 19:44:45 perry Exp $"); +__RCSID("$NetBSD: visual.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -69,8 +69,7 @@ struct xy Visdelta[11] = /*ARGSUSED*/ void -visual(z) - int z __unused; +visual(int z __unused) { int ix, iy; int co; diff --git a/games/trek/warp.c b/games/trek/warp.c index c82aa1b22c8e..f4e07d6023ce 100644 --- a/games/trek/warp.c +++ b/games/trek/warp.c @@ -1,4 +1,4 @@ -/* $NetBSD: warp.c,v 1.8 2003/08/07 09:37:55 agc Exp $ */ +/* $NetBSD: warp.c,v 1.9 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)warp.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: warp.c,v 1.8 2003/08/07 09:37:55 agc Exp $"); +__RCSID("$NetBSD: warp.c,v 1.9 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -62,8 +62,7 @@ __RCSID("$NetBSD: warp.c,v 1.8 2003/08/07 09:37:55 agc Exp $"); */ void -dowarp(fl) - int fl; +dowarp(int fl) { int c; double d; @@ -74,9 +73,7 @@ dowarp(fl) } void -warp(fl, c, d) -int fl, c; -double d; +warp(int fl, int c, double d) { char *p; int course; diff --git a/games/trek/win.c b/games/trek/win.c index 218680e564bc..31c3cfe95479 100644 --- a/games/trek/win.c +++ b/games/trek/win.c @@ -1,4 +1,4 @@ -/* $NetBSD: win.c,v 1.7 2003/08/07 09:37:55 agc Exp $ */ +/* $NetBSD: win.c,v 1.8 2009/05/24 19:18:44 dholland Exp $ */ /* * Copyright (c) 1980, 1993 @@ -34,7 +34,7 @@ #if 0 static char sccsid[] = "@(#)win.c 8.1 (Berkeley) 5/31/93"; #else -__RCSID("$NetBSD: win.c,v 1.7 2003/08/07 09:37:55 agc Exp $"); +__RCSID("$NetBSD: win.c,v 1.8 2009/05/24 19:18:44 dholland Exp $"); #endif #endif /* not lint */ @@ -60,7 +60,7 @@ __RCSID("$NetBSD: win.c,v 1.7 2003/08/07 09:37:55 agc Exp $"); extern jmp_buf env; void -win() +win(void) { long s; const struct cvntab *p = NULL;