Reset getdir_click when exiting therecmdmenu early

This was causing a really annoying to track down bug where
the fuzzer threw the attached iron ball and it could end up
anywhere on the level, emitting a sanity check error.
This commit is contained in:
Pasi Kallinen
2023-09-28 18:19:49 +03:00
parent f64c2070df
commit 0ecb0547e6

View File

@@ -5604,6 +5604,7 @@ dotherecmdmenu(void)
else
ch = there_cmd_menu(x, y, iflags.getdir_click);
gc.clicklook_cc.x = gc.clicklook_cc.y = -1;
iflags.getdir_click = 0;
return (ch && ch != '\033') ? ECMD_TIME : ECMD_OK;
}