| Index: runtime/bin/list_stream.dart
|
| diff --git a/runtime/bin/list_stream.dart b/runtime/bin/list_stream.dart
|
| index da5826ec8e956bbec2039d07d62e81b6fb8fc7ad..f925d529ec8eb7d06a1eefc22d83c082dcf4adbd 100644
|
| --- a/runtime/bin/list_stream.dart
|
| +++ b/runtime/bin/list_stream.dart
|
| @@ -26,6 +26,10 @@ class ListInputStream extends _BaseDataInputStream implements InputStream {
|
| return bytesToRead;
|
| }
|
|
|
| + void _close() {
|
| + _offset = _buffer.length;
|
| + }
|
| +
|
| List<int> _buffer;
|
| int _offset = 0;
|
| }
|
| @@ -38,6 +42,9 @@ class DynamicListInputStream
|
| int available() => _bufferList.length;
|
|
|
| void write(List<int> data) {
|
| + if (_streamMarkedClosed) {
|
| + throw new StreamException.streamClosed();
|
| + }
|
| _bufferList.add(data);
|
| _checkScheduleCallbacks();
|
| }
|
| @@ -57,6 +64,11 @@ class DynamicListInputStream
|
| return bytesToRead;
|
| }
|
|
|
| + void _close() {
|
| + _streamMarkedClosed = true;
|
| + _bufferList.clear();
|
| + }
|
| +
|
| _BufferList _bufferList;
|
| }
|
|
|
|
|