Modified: trunk/LayoutTests/ChangeLog (214242 => 214243)
--- trunk/LayoutTests/ChangeLog 2017-03-22 07:15:16 UTC (rev 214242)
+++ trunk/LayoutTests/ChangeLog 2017-03-22 08:41:44 UTC (rev 214243)
@@ -1,3 +1,18 @@
+2017-03-22 Carlos Garcia Campos <cgar...@igalia.com>
+
+ [GTK] Several WPT tests are failing since they were added in the last update in r213882
+ https://bugs.webkit.org/show_bug.cgi?id=169915
+
+ Reviewed by Michael Catanzaro.
+
+ They fail because libsoup fails to load the requests because the response doesn't include the empty line after the
+ headers while other browsers allow that. Even with libsoup patched we still need platform specific expectations
+ for imported/w3c/web-platform-tests/XMLHttpRequest/getallresponseheaders.htm, because libsoup caches all header
+ names, so the first time foo-test header is cached and then always used no matter what case is used. The results
+ are still valid in any case.
+
+ * platform/gtk/imported/w3c/web-platform-tests/XMLHttpRequest/getallresponseheaders-expected.txt: Added.
+
2017-03-21 Myles C. Maxfield <mmaxfi...@apple.com>
[iOS] Migrate off of CTFontCreateForCSS
Added: trunk/LayoutTests/platform/gtk/imported/w3c/web-platform-tests/XMLHttpRequest/getallresponseheaders-expected.txt (0 => 214243)
--- trunk/LayoutTests/platform/gtk/imported/w3c/web-platform-tests/XMLHttpRequest/getallresponseheaders-expected.txt (rev 0)
+++ trunk/LayoutTests/platform/gtk/imported/w3c/web-platform-tests/XMLHttpRequest/getallresponseheaders-expected.txt 2017-03-22 08:41:44 UTC (rev 214243)
@@ -0,0 +1,4 @@
+
+PASS XMLHttpRequest: getAllResponseHeaders()
+FAIL XMLHttpRequest: getAllResponseHeaders() 1 assert_equals: expected "also-here: Mr. PB\r\newok: lego\r\nfoo-test: 1, 2\r\n" but got "ALSO-here: Mr. PB\r\nfoo-test: 1, 2\r\newok: lego\r\n"
+
Modified: trunk/Tools/ChangeLog (214242 => 214243)
--- trunk/Tools/ChangeLog 2017-03-22 07:15:16 UTC (rev 214242)
+++ trunk/Tools/ChangeLog 2017-03-22 08:41:44 UTC (rev 214243)
@@ -1,3 +1,15 @@
+2017-03-22 Carlos Garcia Campos <cgar...@igalia.com>
+
+ [GTK] Several WPT tests are failing since they were added in the last update in r213882
+ https://bugs.webkit.org/show_bug.cgi?id=169915
+
+ Reviewed by Michael Catanzaro.
+
+ Add libsoup patch to not fail loads when there's no empty line after the headers in responses with no body.
+
+ * gtk/jhbuild.modules:
+ * gtk/patches/libsoup-soup-message-io-Do-not-fail-when-there-s-no-empty-li.patch: Added.
+
2017-03-20 Matt Rajca <mra...@apple.com>
Loosen audio playback restrictions when the volume is 0.
Modified: trunk/Tools/gtk/jhbuild.modules (214242 => 214243)
--- trunk/Tools/gtk/jhbuild.modules 2017-03-22 07:15:16 UTC (rev 214242)
+++ trunk/Tools/gtk/jhbuild.modules 2017-03-22 08:41:44 UTC (rev 214243)
@@ -245,6 +245,7 @@
hash="sha256:ca1ca037e89e8bc7b782559f3ec5d89c9d0b836f505b2f95e008ed517fd6658f">
<patch file="libsoup-auth-Fix-async-authentication-when-flag-SOUP_MESSAGE.patch" strip="1"/>
<patch file="libsoup-auth-do-not-use-cached-credentials-in-lookup-method-.patch" strip="1"/>
+ <patch file="libsoup-soup-message-io-Do-not-fail-when-there-s-no-empty-li.patch" strip="1"/>
</branch>
</autotools>
Added: trunk/Tools/gtk/patches/libsoup-soup-message-io-Do-not-fail-when-there-s-no-empty-li.patch (0 => 214243)
--- trunk/Tools/gtk/patches/libsoup-soup-message-io-Do-not-fail-when-there-s-no-empty-li.patch (rev 0)
+++ trunk/Tools/gtk/patches/libsoup-soup-message-io-Do-not-fail-when-there-s-no-empty-li.patch 2017-03-22 08:41:44 UTC (rev 214243)
@@ -0,0 +1,74 @@
+From bb23caf7db4e9112089e1502aa8c106178095e7e Mon Sep 17 00:00:00 2001
+From: Carlos Garcia Campos <cgar...@igalia.com>
+Date: Tue, 21 Mar 2017 14:19:46 +0100
+Subject: [PATCH] soup-message-io: Do not fail when there's no empty line after
+ headers
+
+The spec says there should be an empty line (\r\n) between the response
+headers and the body. However, some servers don't include the empty line
+when the response doesn't have a body. This is causing several WebKit
+tests to fail, because some of the imported w3c tests do not include
+that empty line. Those tests pass in firefox, chromium and safari, so at
+least those other browsers allow that.
+
+https://bugzilla.gnome.org/show_bug.cgi?id=780352
+---
+ libsoup/soup-message-io.c | 34 ++++++++++++++++++++--------------
+ 1 file changed, 20 insertions(+), 14 deletions(-)
+
+diff --git a/libsoup/soup-message-io.c b/libsoup/soup-message-io.c
+index e893ec2a..ea02b1e3 100644
+--- a/libsoup/soup-message-io.c
++++ b/libsoup/soup-message-io.c
+@@ -229,12 +229,16 @@ read_headers (SoupMessage *msg, gboolean blocking,
+ cancellable, error);
+ io->read_header_buf->len = old_len + MAX (nread, 0);
+ if (nread == 0) {
+- soup_message_set_status (msg, SOUP_STATUS_MALFORMED);
+- g_set_error_literal (error, G_IO_ERROR,
+- G_IO_ERROR_PARTIAL_INPUT,
+- _("Connection terminated unexpectedly"));
++ if (io->read_header_buf->len == 0) {
++ soup_message_set_status (msg, SOUP_STATUS_MALFORMED);
++ g_set_error_literal (error, G_IO_ERROR,
++ G_IO_ERROR_PARTIAL_INPUT,
++ _("Connection terminated unexpectedly"));
++ return FALSE;
++ }
++ break;
+ }
+- if (nread <= 0)
++ if (nread < 0)
+ return FALSE;
+
+ if (got_lf) {
+@@ -251,15 +255,17 @@ read_headers (SoupMessage *msg, gboolean blocking,
+ }
+ }
+
+- /* We need to "rewind" io->read_header_buf back one line.
+- * That SHOULD be two characters (CR LF), but if the
+- * web server was stupid, it might only be one.
+- */
+- if (io->read_header_buf->len < 3 ||
+- io->read_header_buf->data[io->read_header_buf->len - 2] == '\n')
+- io->read_header_buf->len--;
+- else
+- io->read_header_buf->len -= 2;
++ if (got_lf) {
++ /* We need to "rewind" io->read_header_buf back one line.
++ * That SHOULD be two characters (CR LF), but if the
++ * web server was stupid, it might only be one.
++ */
++ if (io->read_header_buf->len < 3 ||
++ io->read_header_buf->data[io->read_header_buf->len - 2] == '\n')
++ io->read_header_buf->len--;
++ else
++ io->read_header_buf->len -= 2;
++ }
+ io->read_header_buf->data[io->read_header_buf->len] = '\0';
+
+ return TRUE;
+--
+2.11.0
+