aboutsummaryrefslogtreecommitdiff
path: root/src/libeinfo.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/libeinfo.c')
-rw-r--r--src/libeinfo.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libeinfo.c b/src/libeinfo.c
index b5d0fa19..7f80c1dc 100644
--- a/src/libeinfo.c
+++ b/src/libeinfo.c
@@ -149,14 +149,14 @@ static bool colour_terminal (void)
static int in_colour = -1;
int i = 0;
+ if (is_env ("RC_NOCOLOR", "yes"))
+ return (false);
+
if (in_colour == 0)
return (false);
if (in_colour == 1)
return (true);
- if (is_env ("RC_NOCOLOR", "yes"))
- return (false);
-
if (! term) {
term = getenv ("TERM");
if (! term)