]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
terminal-util: use ansi_normal() or friends instead of ANSI_NORMAL
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sun, 17 Jan 2021 21:36:42 +0000 (06:36 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Mon, 25 Jan 2021 11:52:12 +0000 (20:52 +0900)
src/basic/terminal-util.c

index 3fc03050ac147a2e8b032128b2086529469a74b5..fc63e134c38daee5e224c3db8b39ce7f1de59836 100644 (file)
@@ -1375,23 +1375,23 @@ void get_log_colors(int priority, const char **on, const char **off, const char
                 if (on)
                         *on = ansi_highlight_red();
                 if (off)
-                        *off = ANSI_NORMAL;
+                        *off = ansi_normal();
                 if (highlight)
-                        *highlight = ANSI_HIGHLIGHT;
+                        *highlight = ansi_highlight();
 
         } else if (priority <= LOG_WARNING) {
                 if (on)
                         *on = ansi_highlight_yellow();
                 if (off)
-                        *off = ANSI_NORMAL;
+                        *off = ansi_normal();
                 if (highlight)
-                        *highlight = ANSI_HIGHLIGHT;
+                        *highlight = ansi_highlight();
 
         } else if (priority <= LOG_NOTICE) {
                 if (on)
-                        *on = ANSI_HIGHLIGHT;
+                        *on = ansi_highlight();
                 if (off)
-                        *off = ANSI_NORMAL;
+                        *off = ansi_normal();
                 if (highlight)
                         *highlight = ansi_highlight_red();
 
@@ -1399,7 +1399,7 @@ void get_log_colors(int priority, const char **on, const char **off, const char
                 if (on)
                         *on = ansi_grey();
                 if (off)
-                        *off = ANSI_NORMAL;
+                        *off = ansi_normal();
                 if (highlight)
                         *highlight = ansi_highlight_red();
         }