Remove null characters from Qt y/n prompt

Fixes issue #566.
This commit is contained in:
Ray Chason
2022-10-23 22:10:20 -04:00
committed by PatR
parent 1ccad11fab
commit ec205c5a7b

View File

@@ -703,7 +703,7 @@ char NetHackQtBind::qt_yn_function(const char *question_,
int result = -1;
if (choices) {
QString choicebuf((int) strlen(choices) + 1, QChar('\0'));
QString choicebuf;
for (const char *p = choices; *p; ++p) {
if (*p == '\033') // <esc> and anything beyond is hidden
break;