From: nethack.allison Date: Wed, 6 Mar 2002 16:51:17 +0000 (+0000) Subject: Ensure that vision is not used during done() X-Git-Tag: MOVE2GIT~3050 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d1b77815096cc0900f802771dfbc2bf8246882be;p=nethack Ensure that vision is not used during done() (and panic() which calls done()) This uses the flag that recently added. At least one crash in the past was caused by ? -> panic() -> done(11) -> * vision_recalc(2) -> newsym() -> crash! if u.ux and u.uy are 0 --- diff --git a/src/end.c b/src/end.c index eb226fd74..a518d8d7c 100644 --- a/src/end.c +++ b/src/end.c @@ -582,8 +582,8 @@ die: program_state.gameover = 1; /* in case of a subsequent panic(), there's no point trying to save */ program_state.something_worth_saving = 0; - /* turn off vision subsystem */ - vision_recalc(2); + /* render vision subsystem inoperative */ + iflags.vision_inited = 0; /* might have been killed while using a disposable item, so make sure it's gone prior to inventory disclosure and creation of bones data */ inven_inuse(TRUE);