From 502e2c6102244fb209ade5a43b1e137559c270dd Mon Sep 17 00:00:00 2001 From: Zeno Rogue Date: Wed, 4 Jan 2023 23:24:52 +0100 Subject: [PATCH] fixed a crash when no last --- dialogs.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dialogs.cpp b/dialogs.cpp index 3a5ae35e..6a5f5ff4 100644 --- a/dialogs.cpp +++ b/dialogs.cpp @@ -886,7 +886,8 @@ EX namespace dialog { last = &(items[i]); } } - set_highlight(*last); + if(last) + set_highlight(*last); } if(DKEY == SDLK_DOWN) { uni = sym = 0;