rust/library
Matthias Krüger d177791791
Rollup merge of #89433 - arlosi:stdin-fix, r=joshtriplett
Fix ctrl-c causing reads of stdin to return empty on Windows.

Pressing ctrl+c (or ctrl+break) on Windows caused a blocking read of stdin to unblock and return empty, unlike other platforms which continue to block.

On ctrl-c, `ReadConsoleW` will return success, but also set `LastError` to `ERROR_OPERATION_ABORTED`.

This change detects this case, and re-tries the call to `ReadConsoleW`.

Fixes #89177. See issue for further details.

Tested on Windows 7 and Windows 10 with both MSVC and GNU toolchains
2021-10-14 16:06:44 +02:00
..
2021-09-15 20:32:35 +02:00
2021-09-28 11:31:47 +09:00
2021-09-28 11:31:47 +09:00
2021-09-21 11:24:08 +02:00