cancelled #herecmd using time

I managed to execute #herecmd by mistake and when I typed ESC to get
out of its menu, monsters took their next turn.  #therecmd behaved
similarly.
This commit is contained in:
PatR
2022-03-21 18:33:34 -07:00
parent b150594d68
commit 6fb0c8a82e

View File

@@ -4395,7 +4395,7 @@ doherecmdmenu(void)
{
char ch = here_cmd_menu(TRUE);
return ch ? ECMD_TIME : ECMD_OK;
return (ch && ch != '\033') ? ECMD_TIME : ECMD_OK;
}
/* #therecmdmenu command, a way to test there_cmd_menu without mouse */
@@ -4412,7 +4412,7 @@ dotherecmdmenu(void)
else
ch = here_cmd_menu(TRUE);
return ch ? ECMD_TIME : ECMD_OK;
return (ch && ch != '\033') ? ECMD_TIME : ECMD_OK;
}
static void