summaryrefslogtreecommitdiff
path: root/games/sail
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2002-02-19 19:39:42 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2002-02-19 19:39:42 +0000
commit3923126b85f9e8a77cab9a41b5a62125acd5b4cd (patch)
tree1a8b19c5db03f8c989fc8228811837b182feb7a3 /games/sail
parentcc03bdb70090357d2393b6ec82e3cde4d5ce5edd (diff)
We live in an ANSI C world. Remove lots of gratuitous #ifdef __STDC__ cruft.
Diffstat (limited to 'games/sail')
-rw-r--r--games/sail/pl_7.c40
-rw-r--r--games/sail/sync.c36
2 files changed, 4 insertions, 72 deletions
diff --git a/games/sail/pl_7.c b/games/sail/pl_7.c
index c78e068f47b..9ebd23654b4 100644
--- a/games/sail/pl_7.c
+++ b/games/sail/pl_7.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pl_7.c,v 1.4 2001/09/05 22:32:28 deraadt Exp $ */
+/* $OpenBSD: pl_7.c,v 1.5 2002/02/19 19:39:36 millert Exp $ */
/* $NetBSD: pl_7.c,v 1.6 1995/04/22 10:37:17 cgd Exp $ */
/*
@@ -38,17 +38,13 @@
#if 0
static char sccsid[] = "@(#)pl_7.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: pl_7.c,v 1.4 2001/09/05 22:32:28 deraadt Exp $";
+static char rcsid[] = "$OpenBSD: pl_7.c,v 1.5 2002/02/19 19:39:36 millert Exp $";
#endif
#endif /* not lint */
#include <sys/ttydefaults.h>
#include "player.h"
-#ifdef __STDC__
#include <stdarg.h>
-#else
-#include <varargs.h>
-#endif
#include <unistd.h>
#include <err.h>
@@ -168,25 +164,12 @@ newturn(n)
/*VARARGS2*/
void
-#ifdef __STDC__
Signal(char *fmt, struct ship *ship, ...)
-#else
-Signal(va_alist)
- va_dcl
-#endif
{
va_list ap;
char format[BUFSIZ];
-#ifndef __STDC__
- char *fmt;
- struct ship *ship;
- va_start(ap);
- fmt = va_arg(ap, const char *);
- ship = va_arg(ap, struct ship *);
-#else
va_start(ap, ship);
-#endif
if (!done_curses) {
va_end(va);
return;
@@ -194,33 +177,18 @@ Signal(va_alist)
if (*fmt == '\7')
putchar(*fmt++);
fmtship(format, sizeof(format), fmt, ship);
-#ifdef __STDC__
(void) vw_printw(scroll_w, format, ap);
-#else
- (void) vwprintw(scroll_w, format, ap);
-#endif
va_end(ap);
Scroll();
}
/*VARARGS2*/
void
-#ifdef __STDC__
Msg(char *fmt, ...)
-#else
-Msg(va_alist)
- va_dcl
-#endif
{
va_list ap;
-#ifndef __STDC__
- char *fmt;
- va_start(ap);
- fmt = va_arg(ap, const char *);
-#else
va_start(ap, fmt);
-#endif
if (!done_curses) {
va_end(ap);
@@ -228,11 +196,7 @@ Msg(va_alist)
}
if (*fmt == '\7')
putchar(*fmt++);
-#ifdef __STDC__
(void) vw_printw(scroll_w, fmt, ap);
-#else
- (void) vwprintw(scroll_w, fmt, ap);
-#endif
va_end(ap);
Scroll();
}
diff --git a/games/sail/sync.c b/games/sail/sync.c
index 97f9e6ef71a..e0832531838 100644
--- a/games/sail/sync.c
+++ b/games/sail/sync.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sync.c,v 1.2 1999/01/18 06:20:54 pjanzen Exp $ */
+/* $OpenBSD: sync.c,v 1.3 2002/02/19 19:39:36 millert Exp $ */
/* $NetBSD: sync.c,v 1.9 1998/08/30 09:19:40 veego Exp $ */
/*
@@ -39,17 +39,13 @@
#if 0
static char sccsid[] = "@(#)sync.c 8.2 (Berkeley) 4/28/95";
#else
-static char rcsid[] = "$OpenBSD: sync.c,v 1.2 1999/01/18 06:20:54 pjanzen Exp $";
+static char rcsid[] = "$OpenBSD: sync.c,v 1.3 2002/02/19 19:39:36 millert Exp $";
#endif
#endif /* not lint */
#include <fcntl.h>
#include <errno.h>
-#ifdef __STDC__
#include <stdarg.h>
-#else
-#include <varargs.h>
-#endif
#include <stdlib.h>
#include <unistd.h>
#include <sys/file.h>
@@ -100,28 +96,13 @@ fmtship(buf, len, fmt, ship)
/*VARARGS3*/
void
-#ifdef __STDC__
makesignal(struct ship *from, const char *fmt, struct ship *ship, ...)
-#else
-makesignal(va_alias)
- va_dcl
-#endif
{
char message[BUFSIZ];
char format[BUFSIZ];
va_list ap;
-#ifndef __STDC__
- struct ship *from;
- const char *fmt;
- struct ship *ship;
- va_start(ap);
- from = va_arg(ap, struct ship *);
- fmt = va_arg(ap, const char *);
- ship = va_arg(ap, struct ship *);
-#else
va_start(ap, ship);
-#endif
fmtship(format, sizeof(format), fmt, ship);
(void) vsprintf(message, format, ap);
va_end(ap);
@@ -129,25 +110,12 @@ makesignal(va_alias)
}
void
-#ifdef __STDC__
makemsg(struct ship *from, const char *fmt, ...)
-#else
-makemsg(va_alias)
- va_dcl
-#endif
{
char message[BUFSIZ];
va_list ap;
-#ifndef __STDC__
- struct ship *from;
- const char *fmt;
- va_start(ap);
- from = va_arg(ap, struct ship *);
- fmt = va_arg(ap, const char *);
-#else
va_start(ap, fmt);
-#endif
(void) vsprintf(message, fmt, ap);
va_end(ap);
Writestr(W_SIGNAL, from, message);