From ff9ec2d9990fbf9a707df063f3d43e9169bdde16 Mon Sep 17 00:00:00 2001 From: Todd Poynor Date: Mon, 9 Sep 2013 14:30:55 -0700 Subject: [PATCH] healthd: perform periodic chores when awake and on battery power Monitor battery/charging status at normal awake rate when on battery power. Bug: 10650797 Change-Id: I914d24af4963ab9d52b03c0a2615ad653ced9b12 --- healthd/healthd.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/healthd/healthd.cpp b/healthd/healthd.cpp index 1719c22f6..9b84c3e8f 100644 --- a/healthd/healthd.cpp +++ b/healthd/healthd.cpp @@ -249,6 +249,9 @@ static void healthd_mainloop(void) { if (events[n].data.ptr) (*(void (*)())events[n].data.ptr)(); } + + if (!nevents) + periodic_chores(); } return;