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

Unified Diff: utils/pub/io.dart

Issue 12213092: Rework Timer interface. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Address comments. Created 7 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 | « tests/standalone/io/test_runner_test.dart ('k') | utils/pub/utils.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: utils/pub/io.dart
diff --git a/utils/pub/io.dart b/utils/pub/io.dart
index d3fa00bba44ceaa34cef3145fbd41c442bf17dc7..0eab87a970e42ce138d17e442e2c7bf475ab76cb 100644
--- a/utils/pub/io.dart
+++ b/utils/pub/io.dart
@@ -702,7 +702,7 @@ Future _doProcess(Function fn, String executable, List<String> args, workingDir,
Future timeout(Future input, int milliseconds, String description) {
bool completed = false;
var completer = new Completer();
- var timer = new Timer(milliseconds, (_) {
+ var timer = new Timer(new Duration(milliseconds: milliseconds), () {
completed = true;
completer.completeError(new TimeoutException(
'Timed out while $description.'));
« no previous file with comments | « tests/standalone/io/test_runner_test.dart ('k') | utils/pub/utils.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698