terminal-util: fix underlying with SYSTEMD_COLORS=no

Fixes #31857.
This commit is contained in:
Yu Watanabe 2024-03-20 04:49:04 +09:00 committed by Zbigniew Jędrzejewski-Szmek
parent 8f76cb55b8
commit 46325d9324

View file

@ -197,7 +197,7 @@ static inline bool colors_enabled(void) {
}
static inline const char *ansi_underline(void) {
return underline_enabled() ? ANSI_UNDERLINE : ANSI_NORMAL;
return underline_enabled() ? ANSI_UNDERLINE : "";
}
static inline const char *ansi_add_underline(void) {