Index: sdk/lib/io/http_parser.dart |
diff --git a/sdk/lib/io/http_parser.dart b/sdk/lib/io/http_parser.dart |
index e7415cf49e33e90a216bbad1d559f65363a8afe2..97d4fd7c8dcc7b64d94f18e0fd1143e806617b56 100644 |
--- a/sdk/lib/io/http_parser.dart |
+++ b/sdk/lib/io/http_parser.dart |
@@ -619,11 +619,8 @@ class _HttpParser extends Stream<_HttpIncoming> { |
if (byte == _CharCode.CR) { |
_state = _State.HEADER_ENDING; |
} else if (byte == _CharCode.LF) { |
- if (_headersEnd()) { |
- return; |
- } else { |
- break; |
- } |
+ _state = _State.HEADER_ENDING; |
+ _index--; // Make the new state see the LF again. |
} else { |
// Start of new header field. |
_headerField.add(_toLowerCaseByte(byte)); |
@@ -697,11 +694,8 @@ class _HttpParser extends Stream<_HttpIncoming> { |
if (byte == _CharCode.CR) { |
_state = _State.HEADER_ENDING; |
} else if (byte == _CharCode.LF) { |
- if (_headersEnd()) { |
- return; |
- } else { |
- break; |
- } |
+ _state = _State.HEADER_ENDING; |
+ _index--; // Make the new state see the LF again. |
} else { |
// Start of new header field. |
_headerField.add(_toLowerCaseByte(byte)); |