Chromium Code Reviews| Index: runtime/bin/chunked_stream.dart |
| diff --git a/runtime/bin/chunked_stream.dart b/runtime/bin/chunked_stream.dart |
| index 8b1e8a1804ff5c4a179b03dd01d0e4b58c664075..d2c66cd3e2cbf130e8d6fd7b215cadb1060ab794 100644 |
| --- a/runtime/bin/chunked_stream.dart |
| +++ b/runtime/bin/chunked_stream.dart |
| @@ -1,4 +1,4 @@ |
| -// Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file |
| +// Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file |
| // for details. All rights reserved. Use of this source code is governed by a |
| // BSD-style license that can be found in the LICENSE file. |
| @@ -110,7 +110,7 @@ class _ChunkedInputStream implements ChunkedInputStream { |
| } |
| // Schedule data callback if enough data in buffer. |
| - if ((_bufferList.length >=_chunkSize || |
| + if ((_bufferList.length >= _chunkSize || |
| (_bufferList.length > 0 && _inputClosed)) && |
| _clientDataHandler !== null && |
| _scheduledDataCallback == null) { |
| @@ -122,6 +122,9 @@ class _ChunkedInputStream implements ChunkedInputStream { |
| _inputClosed && |
| !_closed && |
| _scheduledCloseCallback == null) { |
| + if (_scheduledDataCallback != null) { |
|
Søren Gjesse
2012/02/28 07:40:25
Woops!
|
| + _scheduledDataCallback.cancel(); |
| + } |
| _scheduledCloseCallback = new Timer(issueCloseCallback, 0); |
| } |
| } |