summaryrefslogtreecommitdiffstats
path: root/battlestar
diff options
context:
space:
mode:
authordholland <dholland@NetBSD.org>2010-04-24 00:38:30 +0000
committerdholland <dholland@NetBSD.org>2010-04-24 00:38:30 +0000
commitd2ee870815c331fc0cb7424c35bd71012898df15 (patch)
treee704c7af5e15d5894d6804b464259cb782d1c190 /battlestar
parentbe1c32e4fa4b1b23ec06fbba9266e0f67f20913f (diff)
downloadbsdgames-darwin-d2ee870815c331fc0cb7424c35bd71012898df15.tar.gz
bsdgames-darwin-d2ee870815c331fc0cb7424c35bd71012898df15.tar.zst
bsdgames-darwin-d2ee870815c331fc0cb7424c35bd71012898df15.zip
fflush the score file while signals are blocked to decrease the chance of
it getting corrupted.
Diffstat (limited to 'battlestar')
-rw-r--r--battlestar/command6.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/battlestar/command6.c b/battlestar/command6.c
index 3d563790..0c6c8641 100644
--- a/battlestar/command6.c
+++ b/battlestar/command6.c
@@ -1,4 +1,4 @@
-/* $NetBSD: command6.c,v 1.7 2010/04/02 19:34:44 christos Exp $ */
+/* $NetBSD: command6.c,v 1.8 2010/04/24 00:38:30 dholland Exp $ */
/*
* Copyright (c) 1983, 1993
@@ -34,7 +34,7 @@
#if 0
static char sccsid[] = "@(#)com6.c 8.2 (Berkeley) 4/28/95";
#else
-__RCSID("$NetBSD: command6.c,v 1.7 2010/04/02 19:34:44 christos Exp $");
+__RCSID("$NetBSD: command6.c,v 1.8 2010/04/24 00:38:30 dholland Exp $");
#endif
#endif /* not lint */
@@ -137,6 +137,7 @@ post(int ch)
else
fprintf(score_fp, "\n");
}
+ fflush(score_fp);
sigprocmask(SIG_SETMASK, &osigset, (sigset_t *) 0);
}