From 7c2ffaa8c56692f104be081e5d4a8382cb8fa433 Mon Sep 17 00:00:00 2001 From: Pasi Kallinen Date: Fri, 4 Mar 2022 17:18:05 +0200 Subject: [PATCH] More trap sanity --- src/trap.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/trap.c b/src/trap.c index 4aa7125d1..2e76b0456 100644 --- a/src/trap.c +++ b/src/trap.c @@ -6134,9 +6134,9 @@ trap_sanity_check(void) while (ttmp) { if (!isok(ttmp->tx, ttmp->ty)) - impossible("trap sanity: location"); - if (ttmp->ttyp < 0 || ttmp->ttyp >= TRAPNUM) - impossible("trap sanity: type"); + impossible("trap sanity: location (%i,%i)", ttmp->tx, ttmp->ty); + if (ttmp->ttyp <= NO_TRAP || ttmp->ttyp >= TRAPNUM) + impossible("trap sanity: type (%i)", ttmp->ttyp); ttmp = ttmp->ntrap; } }