Erratic resetting of device polling
@gicmo
Submitted by Christian Kellner Assigned to Richard Hughes @hughsient
Description
While testing a patch I have noticed a burst (three in a row) of "Setup poll for '/org/freedesktop/UPower/devices/battery_BATX' every XX seconds" debug messages. I had a quick look and it seems that the firing of the battery refresh (i.e. the battery polling) causes the 'change_idle_timeout' (up-daemon.c @ 729) being emitted three times in a row, which will completely remove and re-install polling on each invocation. The most obvious fix would be to not listen to the "notify::warning-level" while the poll callback is fired.