aboutsummaryrefslogtreecommitdiff
path: root/src/indicator-power.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/indicator-power.c')
-rw-r--r--src/indicator-power.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/indicator-power.c b/src/indicator-power.c
index ff56fda..d97ecdd 100644
--- a/src/indicator-power.c
+++ b/src/indicator-power.c
@@ -1040,6 +1040,8 @@ count_batteries(GVariant *devices, int *total, int *inuse)
if ((state == UP_DEVICE_STATE_CHARGING) || (state == UP_DEVICE_STATE_DISCHARGING))
++*inuse;
}
+
+ g_variant_unref (device);
}
g_debug("count_batteries found %d batteries (%d are charging/discharging)", *total, *inuse);