diff options
author | jsm <jsm@NetBSD.org> | 2004-02-08 00:32:07 +0000 |
---|---|---|
committer | jsm <jsm@NetBSD.org> | 2004-02-08 00:32:07 +0000 |
commit | 1f37325e997440c903f6a13aee82c9040608bf2f (patch) | |
tree | 36b4f6156e7984db5cd80decd68914de7a3d010b /phantasia/fight.c | |
parent | 812482eb24c871be129d3faf80e646894c96c4aa (diff) | |
download | bsdgames-darwin-1f37325e997440c903f6a13aee82c9040608bf2f.tar.gz bsdgames-darwin-1f37325e997440c903f6a13aee82c9040608bf2f.tar.zst bsdgames-darwin-1f37325e997440c903f6a13aee82c9040608bf2f.zip |
Mark variables changed between setjmp and longjmp as volatile rather
than just taking their addresses.
Diffstat (limited to 'phantasia/fight.c')
-rw-r--r-- | phantasia/fight.c | 12 |
1 files changed, 4 insertions, 8 deletions
diff --git a/phantasia/fight.c b/phantasia/fight.c index 0ce0c739..a44b4d10 100644 --- a/phantasia/fight.c +++ b/phantasia/fight.c @@ -1,4 +1,4 @@ -/* $NetBSD: fight.c,v 1.7 2000/04/27 00:30:53 jdc Exp $ */ +/* $NetBSD: fight.c,v 1.8 2004/02/08 00:32:07 jsm Exp $ */ /* * fight.c Phantasia monster fighting routines @@ -10,18 +10,14 @@ void encounter(particular) int particular; { - bool firsthit = Player.p_blessing; /* set if player gets the - * first hit */ - int flockcnt = 1; /* how many time flocked */ + volatile bool firsthit = Player.p_blessing; /* set if player gets + * the first hit */ + volatile int flockcnt = 1; /* how many time flocked */ /* let others know what we are doing */ Player.p_status = S_MONSTER; writerecord(&Player, Fileloc); -#if __GNUC__ - (void)&firsthit; /* XXX shut up gcc */ -#endif - #ifdef SYS5 flushinp(); #endif |