fix crash

Signed-off-by: nppangband <nppangbanddev@verizon.net>