diff options
-rw-r--r-- | lib/colors.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/lib/colors.c b/lib/colors.c index 7349063d0..7b16a15b7 100644 --- a/lib/colors.c +++ b/lib/colors.c @@ -180,7 +180,6 @@ static void colors_debug(struct ul_color_ctl *cc) } fputc('\n', stdout); } - #endif /* @@ -285,8 +284,8 @@ static int colors_readdir(struct ul_color_ctl *cc, const char *dirname) continue; /* filter out by names */ - if (tk_namesz != namesz - || strncmp(tk_name, cc->utilname, namesz) != 0) + if (tk_namesz && (tk_namesz != namesz || + strncmp(tk_name, cc->utilname, namesz) != 0)) continue; if (tk_termsz && (termsz == 0 || tk_termsz != termsz || |