wm: Fix some timerfd leaks.
There were a few places where I wasn't removing one-shot
timeouts after they fired. This corrects that, adds a
DCHECK() to EventLoop's d'tor to make these easier to catch,
and makes mostly-cosmetic cleanups to some other
timeout-related code.
BUG=chromium-os:18556
TEST=verified that updated tests pass; also ran this code, locked and unlocked the screen several times, and checked that what I think is the expected number of timer FDs are open (two: one for the compositor and one for the watchdog) -- with the old code, there are more open and the number grows whenever I lock and unlock the screen
Change-Id: I307921bdf35a5c787881fb27911f1989427bbb65
Reviewed-on: http://gerrit.chromium.org/gerrit/5222
Reviewed-by: Scott Violet <[email protected]>
Reviewed-by: Daniel Erat <[email protected]>
Tested-by: Daniel Erat <[email protected]>
22 files changed