event/TimeoutMonitor: reset "active" flag before invoking OnTimeout()

The IsActive() method returned true even if the timer was not active,
after it completed once.  This broke the state file timer, and the
state file was not saved periodically.
This commit is contained in:
Max Kellermann 2014-08-24 13:13:12 +02:00
parent c38f29ce56
commit d16fb79708
2 changed files with 4 additions and 1 deletions

1
NEWS
View File

@ -2,6 +2,7 @@ ver 0.18.13 (not yet released)
* decoder
- dsdiff, dsf: fix endless loop on malformed file
- ffmpeg: support ffmpeg/libav version 11
* fix state file saver
* fix build failure on Darwin
ver 0.18.12 (2014/07/30)

View File

@ -64,7 +64,9 @@ TimeoutMonitor::ScheduleSeconds(unsigned s)
void
TimeoutMonitor::Run()
{
#ifndef USE_EPOLL
#ifdef USE_EPOLL
active = true;
#else
Cancel();
#endif