When you run the ReadConsoleInputA function in Windows 8 or Windows 10, the function fails to return the correct double-byte characters (DBCS). Applications that use the ReadConsoleInputA function to read keyboard input from the console may experience unexpected behavior, or they may crash. Applications that call C run-time functions such as _getch() are also affected.
The ReadConsoleInputA function does not advance to the second character code of a DBCS character when a single INPUT_RECORD structure is read in each call.
Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.
To work around this issue, use one of the following methods:
- Use the ReadConsoleInputW function or the corresponding Unicode version of the C run-time function, such as _getwch().
- Read two INPUT_RECORD structures when you call ReadConsoleInputA.
文章 ID：3165318 - 上次审阅时间：2016年5月19日 - 修订版本： 1