[PATCH 20/22] dmesg: parse level when --color is used

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



When user runs with --color it should not need to be combined with
filtering per level or facility, or decoding.

Signed-off-by: Sami Kerola <kerolasa@xxxxxx>
---
 sys-utils/dmesg.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/sys-utils/dmesg.c b/sys-utils/dmesg.c
index ddab9b4..080fe7d 100644
--- a/sys-utils/dmesg.c
+++ b/sys-utils/dmesg.c
@@ -658,7 +658,7 @@ static int get_next_syslog_record(struct dmesg_control *ctl,
 			continue;	/* error or empty line? */
 
 		if (*begin == '<') {
-			if (ctl->fltr_lev || ctl->fltr_fac || ctl->decode)
+			if (ctl->fltr_lev || ctl->fltr_fac || ctl->decode || ctl->color)
 				begin = parse_faclev(begin + 1, &rec->facility,
 						     &rec->level);
 			else
-- 
1.8.1.1

--
To unsubscribe from this list: send the line "unsubscribe util-linux" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux