diff options
author | Holger Hans Peter Freyther <zecke@selfish.org> | 2011-06-29 00:32:27 +0200 |
---|---|---|
committer | Holger Hans Peter Freyther <zecke@selfish.org> | 2011-06-29 00:32:27 +0200 |
commit | 49c376dbf60738448b0c925865d37042d96ebefd (patch) | |
tree | a94a5d1f9b816d7742b955d3b071fcfe87621471 | |
parent | 3386942ce2435dfa63754f47c25e1c46d9a2db80 (diff) |
timer: Dispatch the whole timer in the main block.
-rw-r--r-- | Timer.st | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -125,7 +125,7 @@ bit difficult to do this race free.'> (Delay forSeconds: 1) wait. now := DateTime now. - self fireTimers: now. + OsmoDispatcher dispatchBlock: [self fireTimers: now]. ] ] @@ -143,7 +143,11 @@ bit difficult to do this race free.'> copy do: [:each | each timeout > now ifTrue: [^true]. sem critical: [queue remove: each]. - OsmoDispatcher dispatchBlock: [each fire]. + [ + each fire + ] on: Error do: [:e | + e logException: 'Execution of timer failed: %1' % {e tag} area: #timer. + ]. ]. ] ] |