aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/http2.c9
-rw-r--r--tests/data/test18015
2 files changed, 11 insertions, 3 deletions
diff --git a/lib/http2.c b/lib/http2.c
index 658d6141e..9410cf282 100644
--- a/lib/http2.c
+++ b/lib/http2.c
@@ -1062,6 +1062,15 @@ CURLcode Curl_http2_switched(struct connectdata *conn,
return CURLE_HTTP2;
}
+ /* Try to send some frames since we may read SETTINGS already. */
+ rv = nghttp2_session_send(httpc->h2);
+
+ if(rv != 0) {
+ failf(data, "nghttp2_session_send() failed: %s(%d)",
+ nghttp2_strerror(rv), rv);
+ return CURLE_HTTP2;
+ }
+
return CURLE_OK;
}
diff --git a/tests/data/test1801 b/tests/data/test1801
index a95e76a22..0aedfed51 100644
--- a/tests/data/test1801
+++ b/tests/data/test1801
@@ -23,7 +23,6 @@ lies!
<datacheck>
HTTP/1.1 101 Switching!
-
</datacheck>
# listen to the upgrade request!
@@ -62,9 +61,9 @@ Upgrade: %H2CVER
HTTP2-Settings: AAMAAABkAAQAAP__
</protocol>
-# nothing is returned, because no HTTP/2 data nor headers was handled
+# CURLE_HTTP2: Send failure: Broken pipe
<errorcode>
-56
+16
</errorcode>
</verify>
</testcase>