eric pouech (@epo) commented about programs/cmd/batch.c:
DWORD charsRead; BOOL status; DWORD i;
- DWORD conmode, oldconmode;
- CONSOLE_READCONSOLE_CONTROL control;
- GetConsoleMode(h, &oldconmode);
I think this would be better handled by rewriting the code as:
`if (GetConsoleMode(h, &oldmode)) {`
`/* put all console related code here */`
`SetConsoleMode(h, oldmode);`
`}`
`else`
`{`
`/* other handles (file, pipe) */`