diff options
| author | Felix Domke <tmbinc@elitedvb.net> | 2005-11-25 03:12:16 +0000 |
|---|---|---|
| committer | Felix Domke <tmbinc@elitedvb.net> | 2005-11-25 03:12:16 +0000 |
| commit | 6f1188bea106d335f993729e4971770deac88619 (patch) | |
| tree | c84dbf0b17ebf52fee756d1ec7ea1e6fd97fccc7 /lib/base/ebase.cpp | |
| parent | 52f9ca652c2371b06715265ff74b5b6a680f30b2 (diff) | |
| download | enigma2-6f1188bea106d335f993729e4971770deac88619.tar.gz enigma2-6f1188bea106d335f993729e4971770deac88619.zip | |
base: fix a very theoretical performance problem
Diffstat (limited to 'lib/base/ebase.cpp')
| -rw-r--r-- | lib/base/ebase.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/base/ebase.cpp b/lib/base/ebase.cpp index 7f84cc91..a3ecbc7c 100644 --- a/lib/base/ebase.cpp +++ b/lib/base/ebase.cpp @@ -227,6 +227,9 @@ void eMainloop::processOneEvent() /* when we not processed anything, check timers. */ if (!ret) { + /* we know that this time has passed. */ + now += poll_timeout; + singleLock s(recalcLock); /* this will never change while we have the recalcLock */ @@ -235,7 +238,7 @@ void eMainloop::processOneEvent() return; /* process all timers which are ready. first remove them out of the list. */ - while ((!m_timer_list.empty()) && (m_timer_list.begin()->getNextActivation() < now)) + while ((!m_timer_list.empty()) && (m_timer_list.begin()->getNextActivation() <= now)) m_timer_list.begin()->activate(); } } |
