aboutsummaryrefslogtreecommitdiff
path: root/modules/devices/battery.c
diff options
context:
space:
mode:
authorLeandro Pereira <leandro@hardinfo.org>2020-05-17 11:40:45 -0700
committerLeandro Pereira <leandro@hardinfo.org>2020-05-17 11:40:45 -0700
commit8190734fe0fd5a589fb16b17abfcf3dea31a8a62 (patch)
tree53c82a21d67a013f993902a5b771ce6b745d8330 /modules/devices/battery.c
parent9113356173ed569ce22573dc6d1e05c922bf2340 (diff)
Fix more formatting errors
Diffstat (limited to 'modules/devices/battery.c')
-rw-r--r--modules/devices/battery.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/modules/devices/battery.c b/modules/devices/battery.c
index 6d50a52d..d2b7189c 100644
--- a/modules/devices/battery.c
+++ b/modules/devices/battery.c
@@ -82,9 +82,9 @@ __scan_battery_apcupsd(void)
battery_list = h_strdup_cprintf("[%s]\n", battery_list, ups_fields[i].key);
} else {
/* there's a name: adds a line */
+ const gchar *name = g_hash_table_lookup(ups_data, ups_fields[i].key);
battery_list = h_strdup_cprintf("%s=%s\n", battery_list,
- ups_fields[i].name,
- g_hash_table_lookup(ups_data, ups_fields[i].key));
+ ups_fields[i].name, name);
}
}