mirror of
https://github.com/neovim/neovim.git
synced 2024-12-20 19:25:11 -07:00
Replace explicit uv_guest_handle(fd) == UV_TTY by os_isatty
This commit is contained in:
parent
aea2e2cb12
commit
61b7b2d81a
@ -167,7 +167,7 @@ static void read_cb(RStream *rstream, void *data, bool at_eof)
|
||||
if (at_eof) {
|
||||
if (!started_reading
|
||||
&& rstream_is_regular_file(rstream)
|
||||
&& uv_guess_handle(2) == UV_TTY) {
|
||||
&& os_isatty(STDERR_FILENO)) {
|
||||
// Read error. Since stderr is a tty we switch to reading from it. This
|
||||
// is for handling for cases like "foo | xargs vim" because xargs
|
||||
// redirects stdin from /dev/null. Previously, this was done in ui.c
|
||||
|
Loading…
Reference in New Issue
Block a user