Index: sdk/lib/io/http_headers.dart |
diff --git a/sdk/lib/io/http_headers.dart b/sdk/lib/io/http_headers.dart |
index 31ed38afcca226fa46f16fa04c0ff494e0a204ad..8eb0f34c6d496b301645aebf5004671324634458 100644 |
--- a/sdk/lib/io/http_headers.dart |
+++ b/sdk/lib/io/http_headers.dart |
@@ -320,7 +320,7 @@ class _HttpHeaders implements HttpHeaders { |
return true; |
} |
- void _finalize() { |
+ void _synchronize() { |
// If the content length is not known make sure chunked transfer |
// encoding is used for HTTP 1.1. |
if (contentLength < 0) { |
@@ -337,6 +337,10 @@ class _HttpHeaders implements HttpHeaders { |
protocolVersion == "1.1") { |
contentLength = -1; |
} |
+ } |
+ |
+ void _finalize() { |
+ _synchronize(); |
_mutable = false; |
} |