Skip to content

Commit 3e0b322

Browse files
committed
readline: Assume "unknown" terminal type by default
This patch modifies the `_rl_init_terminal_io` function to pass `unknown` terminal type instead of `dumb` when no terminal name is provided by the caller (e.g. when the `TERM` environment variable is not set on Win32). This ensures that the termcap provider (e.g. ncurses) resolves the default preferred terminal type instead of using the `dumb` terminal type. Signed-off-by: Stephanos Ioannidis <root@stephanos.io>
1 parent bde8cbe commit 3e0b322

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

readline/readline/terminal.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -478,7 +478,7 @@ _rl_init_terminal_io (const char *terminal_name)
478478
tty = rl_instream ? fileno (rl_instream) : 0;
479479

480480
if (term == 0)
481-
term = "dumb";
481+
term = "unknown";
482482

483483
dumbterm = STREQ (term, "dumb");
484484

0 commit comments

Comments
 (0)