Index: runtime/bin/builtin.dart |
diff --git a/runtime/bin/builtin.dart b/runtime/bin/builtin.dart |
index 7e31b3c13040d771d1cdda8db1e66b299e94ecba..59338260107e067d1ca223b8823ae4877b027533 100644 |
--- a/runtime/bin/builtin.dart |
+++ b/runtime/bin/builtin.dart |
@@ -295,6 +295,7 @@ _loadDataAsyncLoadPort(int tag, |
Uri resourceUri) { |
var receivePort = new ReceivePort(); |
receivePort.first.then((dataOrError) { |
+ receivePort.close(); |
if (dataOrError is List<int>) { |
_loadScript(tag, uri, libraryUri, dataOrError); |
} else { |
@@ -303,6 +304,7 @@ _loadDataAsyncLoadPort(int tag, |
_asyncLoadError(tag, uri, libraryUri, error); |
} |
}).catchError((e) { |
+ receivePort.close(); |
// Wrap inside a LoadError unless we are already propagating a previously |
// seen LoadError. |
var error = (e is LoadError) ? e : new LoadError(e.toString); |