Index: sdk/lib/_internal/pub/lib/src/io.dart |
diff --git a/sdk/lib/_internal/pub/lib/src/io.dart b/sdk/lib/_internal/pub/lib/src/io.dart |
index e9a13167539da2e8b797058d4c407224af1170b9..e9d803b3e2911bac1c09b3cfe2f85237a05ce53a 100644 |
--- a/sdk/lib/_internal/pub/lib/src/io.dart |
+++ b/sdk/lib/_internal/pub/lib/src/io.dart |
@@ -422,7 +422,7 @@ Future drainStream(Stream stream) { |
/// will succeed when [EventSink] is closed or fail with any errors that occur |
/// while writing. |
Pair<EventSink, Future> consumerToSink(StreamConsumer consumer) { |
- var controller = new StreamController(); |
+ var controller = new StreamController(sync: true); |
var done = controller.stream.pipe(consumer); |
return new Pair<EventSink, Future>(controller.sink, done); |
} |
@@ -739,7 +739,7 @@ ByteStream createTarGz(List contents, {baseDir}) { |
contents.forEach((file) => buffer.write('$file\n')); |
log.fine(buffer.toString()); |
- var controller = new StreamController<List<int>>(); |
+ var controller = new StreamController<List<int>>(sync: true); |
if (baseDir == null) baseDir = path.current; |
baseDir = path.absolute(baseDir); |