From 5c1c653098f6b3fede2d9d72e9f6f743bc4703bb Mon Sep 17 00:00:00 2001 From: Patryk Obara Date: Fri, 27 Dec 2019 16:12:26 +0100 Subject: [PATCH] Print a newline after user makes a choice Previously, this command expected newline to be injected by the shell (which was incorrect behaviour, as shell was skipping it in batch files). --- src/shell/shell_cmds.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/shell/shell_cmds.cpp b/src/shell/shell_cmds.cpp index 4993b1b0..8c9d8a85 100644 --- a/src/shell/shell_cmds.cpp +++ b/src/shell/shell_cmds.cpp @@ -1367,7 +1367,8 @@ void DOS_Shell::CMD_CHOICE(char * args){ DOS_ReadFile (STDIN,&c,&n); } while (!c || !(ptr = strchr(rem,(optS?c:toupper(c))))); c = optS?c:(Bit8u)toupper(c); - DOS_WriteFile (STDOUT,&c, &n); + DOS_WriteFile(STDOUT, &c, &n); + WriteOut_NoParsing("\n"); dos.return_code = (Bit8u)(ptr-rem+1); }