From 2f4d6546de4bed086cd7acb8b6f99d68da64f02a Mon Sep 17 00:00:00 2001 From: Leandro Pereira Date: Sat, 29 Jun 2019 19:50:15 -0700 Subject: Show Warning icon in CPU Vulnerabilities section if unmitigated --- modules/computer.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'modules') diff --git a/modules/computer.c b/modules/computer.c index 5e81f386..3e7b9fec 100644 --- a/modules/computer.c +++ b/modules/computer.c @@ -603,9 +603,11 @@ gchar *callback_security(void) if (!contents) continue; - info_group_add_fields(vulns, - info_field(vuln, idle_free(contents)), - info_field_last()); + struct InfoField field = info_field(vuln, idle_free(contents)); + if (g_strstr_len(contents, -1, "Vulnerable")) + field = info_field_with_icon(field, "dialog-warning.png"); + + info_group_add_fields(vulns, field, info_field_last()); } g_dir_close(dir); -- cgit v1.2.3