diff options
author | mrg <mrg@NetBSD.org> | 1997-11-24 01:47:26 +0000 |
---|---|---|
committer | mrg <mrg@NetBSD.org> | 1997-11-24 01:47:26 +0000 |
commit | d12fe4fbf48b540d01aee7773682868627d4aede (patch) | |
tree | 6e841d1df642de76898fa6300c3f2149bf59fb74 /phantasia/setup.c | |
parent | 4fe1a63ce6ffadff8b945cdf09ffd497b050f11d (diff) | |
download | bsdgames-darwin-d12fe4fbf48b540d01aee7773682868627d4aede.tar.gz bsdgames-darwin-d12fe4fbf48b540d01aee7773682868627d4aede.tar.zst bsdgames-darwin-d12fe4fbf48b540d01aee7773682868627d4aede.zip |
don't clobber the score file!
Diffstat (limited to 'phantasia/setup.c')
-rw-r--r-- | phantasia/setup.c | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/phantasia/setup.c b/phantasia/setup.c index 7fc1d666..6727d265 100644 --- a/phantasia/setup.c +++ b/phantasia/setup.c @@ -1,4 +1,4 @@ -/* $NetBSD: setup.c,v 1.7 1997/10/13 02:18:37 lukem Exp $ */ +/* $NetBSD: setup.c,v 1.8 1997/11/24 01:47:26 mrg Exp $ */ /* * setup.c - set up all files for Phantasia @@ -98,6 +98,13 @@ main(argc, argv) continue; } + if (!strcmp(*filename, _PATH_SCORE)) + /* do not reset score file if it already exists */ + { + ++filename; + continue; + } + if (unlink(path) < 0) Error("Cannot unlink %s.\n", path); /*NOTREACHED*/ |