Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(72)

Unified Diff: runtime/lib/timer_impl.dart

Issue 971193002: - Make sure we schedule another wakeup when handling a timeout (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/lib/timer_impl.dart
===================================================================
--- runtime/lib/timer_impl.dart (revision 44159)
+++ runtime/lib/timer_impl.dart (working copy)
@@ -115,7 +115,7 @@
class _Timer implements Timer {
// Cancels the timer in the event handler.
- static const int _NO_TIMER = -1;
+ static const _NO_TIMER = -1;
// We distinguish what kind of message arrived based on the value being sent.
static const _ZERO_EVENT = 1;
@@ -129,7 +129,7 @@
// We use an id to be able to sort timers with the same expiration time.
// ids are recycled after ID_MASK enqueues or when the timer queue is empty.
- static int _ID_MASK = 0x1fffffff;
+ static const _ID_MASK = 0x1fffffff;
static int _idCount = 0;
static RawReceivePort _receivePort;
@@ -402,6 +402,7 @@
assert(pendingTimers.length > 0);
} else {
assert(msg == _TIMEOUT_EVENT);
+ _scheduledWakeupTime = null; // Consumed the last scheduled wakeup now.
pendingTimers = _queueFromTimeoutEvent();
}
_runTimers(pendingTimers);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698