summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--sail/dr_main.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/sail/dr_main.c b/sail/dr_main.c
index 893a7702..f264b347 100644
--- a/sail/dr_main.c
+++ b/sail/dr_main.c
@@ -1,4 +1,4 @@
-/* $NetBSD: dr_main.c,v 1.12 2003/08/07 09:37:42 agc Exp $ */
+/* $NetBSD: dr_main.c,v 1.13 2009/03/02 06:44:22 dholland Exp $ */
/*
* Copyright (c) 1983, 1993
@@ -34,10 +34,11 @@
#if 0
static char sccsid[] = "@(#)dr_main.c 8.2 (Berkeley) 4/16/94";
#else
-__RCSID("$NetBSD: dr_main.c,v 1.12 2003/08/07 09:37:42 agc Exp $");
+__RCSID("$NetBSD: dr_main.c,v 1.13 2009/03/02 06:44:22 dholland Exp $");
#endif
#endif /* not lint */
+#include <err.h>
#include <signal.h>
#include <stdio.h>
#include <stdlib.h>
@@ -57,14 +58,12 @@ dr_main(void)
signal(SIGQUIT, SIG_IGN);
signal(SIGTSTP, SIG_IGN);
if (game < 0 || game >= NSCENE) {
- fprintf(stderr, "DRIVER: Bad game number %d\n", game);
- exit(1);
+ errx(1, "driver: Bad game number %d", game);
}
cc = &scene[game];
ls = SHIP(cc->vessels);
if (sync_open() < 0) {
- perror("driver: syncfile");
- exit(1);
+ err(1, "driver: syncfile");
}
for (n = 0; n < NNATION; n++)
nat[n] = 0;