neovim

Neovim text editor
git clone https://git.dasho.dev/neovim.git
Log | Files | Refs | README

commit e03ecb7d31c10aab8a8acbfb3cdd7ec558cd49eb
parent b4a92309f8f5ee4e579cee72ef352451a60733b8
Author: Enan Ajmain <3nan.ajmain@gmail.com>
Date:   Wed, 15 Feb 2023 01:15:28 +0600

fix: uv_tty_set_mode failed in Windows #22264

Problem:  uv_tty_set_mode on stdout in Windows exits with error.
Cause:    Windows cannot set the properties of the output of a tty.
Solution: Remove call to uv_tty_set_mode.

Ref: #21445
Ref: https://github.com/libuv/libuv/commit/88634c1405097c19582e870d278dd0e29dc55455#r100598822
Diffstat:
Msrc/nvim/tui/tui.c | 7+------
1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/src/nvim/tui/tui.c b/src/nvim/tui/tui.c @@ -359,12 +359,7 @@ static void terminfo_start(TUIData *tui) if (ret) { ELOG("uv_tty_init failed: %s", uv_strerror(ret)); } -#ifdef MSWIN - ret = uv_tty_set_mode(&tui->output_handle.tty, UV_TTY_MODE_RAW); - if (ret) { - ELOG("uv_tty_set_mode failed: %s", uv_strerror(ret)); - } -#else +#ifndef MSWIN int retry_count = 10; // A signal may cause uv_tty_set_mode() to fail (e.g., SIGCONT). Retry a // few times. #12322