summaryrefslogtreecommitdiff
path: root/games/sail
diff options
context:
space:
mode:
authorPaul Janzen <pjanzen@cvs.openbsd.org>1999-01-18 21:53:23 +0000
committerPaul Janzen <pjanzen@cvs.openbsd.org>1999-01-18 21:53:23 +0000
commitfe46565fb8bff53ebcafa4f9aca2a70eb5ca0032 (patch)
tree36e332c1fa2078c01995bc39812e993da0ab77ee /games/sail
parent05cf270e66e47b2531cc36a550970a99a229dada (diff)
Only use __attribute__ if __GNUC__ is defined
Diffstat (limited to 'games/sail')
-rw-r--r--games/sail/extern.h6
-rw-r--r--games/sail/pl_1.c12
2 files changed, 13 insertions, 5 deletions
diff --git a/games/sail/extern.h b/games/sail/extern.h
index ce4a8432410..df1efb84510 100644
--- a/games/sail/extern.h
+++ b/games/sail/extern.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: extern.h,v 1.1 1999/01/18 21:14:15 pjanzen Exp $ */
+/* $OpenBSD: extern.h,v 1.2 1999/01/18 21:53:22 pjanzen Exp $ */
/* $NetBSD: extern.h,v 1.8 1998/09/13 15:27:30 hubertf Exp $ */
/*
@@ -44,6 +44,10 @@
#include <sys/types.h>
#include "machdep.h"
+#ifndef __GNUC__
+#define __attribute__(x)
+#endif
+
/* program mode */
int mode;
jmp_buf restart;
diff --git a/games/sail/pl_1.c b/games/sail/pl_1.c
index a67ff635adf..b8959e2192b 100644
--- a/games/sail/pl_1.c
+++ b/games/sail/pl_1.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: pl_1.c,v 1.4 1999/01/18 06:20:53 pjanzen Exp $ */
+/* $OpenBSD: pl_1.c,v 1.5 1999/01/18 21:53:22 pjanzen Exp $ */
/* $NetBSD: pl_1.c,v 1.3 1995/04/22 10:37:07 cgd Exp $ */
/*
@@ -38,7 +38,7 @@
#if 0
static char sccsid[] = "@(#)pl_1.c 8.1 (Berkeley) 5/31/93";
#else
-static char rcsid[] = "$OpenBSD: pl_1.c,v 1.4 1999/01/18 06:20:53 pjanzen Exp $";
+static char rcsid[] = "$OpenBSD: pl_1.c,v 1.5 1999/01/18 21:53:22 pjanzen Exp $";
#endif
#endif /* not lint */
@@ -48,6 +48,10 @@ static char rcsid[] = "$OpenBSD: pl_1.c,v 1.4 1999/01/18 06:20:53 pjanzen Exp $"
#include <sys/wait.h>
#include <unistd.h>
+#ifndef __GNUC__
+#define __attribute__(x)
+#endif
+
/*
* If we get here before a ship is chosen, then ms == 0 and
* we don't want to update the score file, or do any Write's either.
@@ -122,14 +126,14 @@ leave(conditions)
void
choke(n)
- int n;
+ int n __attribute__((unused));
{
leave(LEAVE_QUIT);
}
void
child(n)
- int n;
+ int n __attribute__((unused));
{
union wait status;
int pid;