diff options
author | phk <phk@FreeBSD.org> | 2001-05-23 21:01:01 +0000 |
---|---|---|
committer | phk <phk@FreeBSD.org> | 2001-05-23 21:01:01 +0000 |
commit | 35be3f27b219ffed4f5dc879ec5fd3455e8237e6 (patch) | |
tree | d83f516930f2f1871d1ad5d89a993c49ea09c448 /games/rogue | |
parent | e328ed5df347fa845f05fe595a45d69c20f9d47b (diff) | |
download | FreeBSD-src-35be3f27b219ffed4f5dc879ec5fd3455e8237e6.zip FreeBSD-src-35be3f27b219ffed4f5dc879ec5fd3455e8237e6.tar.gz |
When a game ends that makes the top 10, the function insert_score in
score.c is called to make the new score file. But the case for KFIRE
(killed by fire) incorrectly uses strcpy instead of strcat (all the
other cases use strcat). This puts the string in the wrong place and
corrupts the score file.
PR: 13278
Submitted by: Mark W. Krentel krentel@dreamscape.com
Diffstat (limited to 'games/rogue')
-rw-r--r-- | games/rogue/score.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/games/rogue/score.c b/games/rogue/score.c index b1c9ccd..1f0794a 100644 --- a/games/rogue/score.c +++ b/games/rogue/score.c @@ -360,7 +360,7 @@ const object *monster; (void) strcat(buf, "a total winner"); break; case KFIRE: - (void) strcpy(buf, "killed by fire"); + (void) strcat(buf, "killed by fire"); break; } } else { |