XMLHttpRequest has the wrong fallback encoding
[WebKit-https.git] / Source / WebCore / ChangeLog
index 2776867..04e4bdb 100644 (file)
@@ -1,3 +1,25 @@
+2019-04-17  Rob Buis  <rbuis@igalia.com>
+
+        XMLHttpRequest has the wrong fallback encoding
+        https://bugs.webkit.org/show_bug.cgi?id=191741
+
+        Reviewed by Alex Christensen.
+
+        Allow overriding the response charset as specified here:
+        https://xhr.spec.whatwg.org/#final-charset
+
+        Behavior matches Firefox and Chrome.
+
+        Tests: imported/w3c/web-platform-tests/encoding/replacement-encodings.any.html
+               imported/w3c/web-platform-tests/encoding/replacement-encodings.any.worker.html
+               imported/w3c/web-platform-tests/encoding/unsupported-encodings.any.html
+               imported/w3c/web-platform-tests/encoding/unsupported-encodings.any.worker.html
+
+        * xml/XMLHttpRequest.cpp:
+        (WebCore::XMLHttpRequest::finalResponseCharset const):
+        (WebCore::XMLHttpRequest::createDecoder const):
+        * xml/XMLHttpRequest.h:
+
 2019-04-16  Antoine Quint  <graouts@apple.com>
 
         Opt Google Maps into simulated mouse events dispatch quirk