]> granicus.if.org Git - nethack/commit
fix object lost panic (trunc only)
authornethack.rankin <nethack.rankin>
Thu, 8 Dec 2005 05:45:43 +0000 (05:45 +0000)
committernethack.rankin <nethack.rankin>
Thu, 8 Dec 2005 05:45:43 +0000 (05:45 +0000)
commitbaff3bc88b64d5681e2d2ac9f7ba10e27ffe1c3f
treeccec50617cb5e4553a487ada7b3d9f6d27286df1
parent6a40b203ed79f37308c5076edf751c7cee9dc655
fix object lost panic (trunc only)

     While testing some killer_xname() changes, I noticed that it was
feasible to avoid having some gear destroyed by causing a hangup after
getting the destruction message.  And while testing the fix for that, I
stumbled across a panic situation (not caused by my changes).  If you
survive entering lava while wearing water walking boots (and aren't fire
resistant yourself, and don't have enough hit points to survive 6d6
damage, and your boots aren't fireproofed...), having those boots be
destroyed will dump you back into the same lava recursively (lava_effects
-> Boots_off -> spoteffects -> lava_effects).  And if you survive that
(wizard/explore mode or life-saving), there will be a panic when finishing
deletion of the boots (useupall) because the recursive call will have
already done it (since they aren't worn anymore when inner call handles
them, no additional recursion gets triggered and object deletion happens).

     Some of the other stuff I was working on is mixed in here because
this is the configuration I ended up using to test the panic fix.

     Several Makefiles are missing the dependency for context.h (post-3.4.3
revision).  If yours is, then you'll need to force a full rebuild after
applying this or you'll end up with havoc.  (Mine was, but I noticed that
the expected full build wasn't happening and interrupted it to fix that.)
doc/fixes34.4
include/context.h
src/do_wear.c
src/read.c
src/trap.c