Skip to content

Commit 03aa566

Browse files
authored
Disable ANSI when stdout is not a valid file descriptor (#12565)
Fixes issue reported in #12564 comments
1 parent afd4de8 commit 03aa566

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/elixir/src/elixir.erl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ start(_Type, _Args) ->
6060
{ok, _} -> ok;
6161
undefined ->
6262
%% Remove prim_tty module check as well as checks from scripts on Erlang/OTP 26
63-
ANSIEnabled = erlang:module_loaded(prim_tty) andalso prim_tty:isatty(stdout),
63+
ANSIEnabled = erlang:module_loaded(prim_tty) andalso (prim_tty:isatty(stdout) == true),
6464
application:set_env(elixir, ansi_enabled, ANSIEnabled)
6565
end,
6666

0 commit comments

Comments
 (0)