summaryrefslogtreecommitdiff
path: root/lib/http.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2021-01-24 18:59:21 +0100
committerDaniel Stenberg <daniel@haxx.se>2021-01-24 18:59:21 +0100
commit12d6b851f17a4bf628c5278a9b54a92367ad1c16 (patch)
treead0e9fd01e015671a8028423ea62c4cee85cced4 /lib/http.c
parentecb13416e316fc1c781f865d2bb7e74462ef793b (diff)
downloadcurl-bagder/h2-conn-data.tar.gz
http2: remove conn->data usebagder/h2-conn-data
Starting here, the code sets the 'data' pointer as user-data even for the connection, and the callbacks need to find the connection using 'data->conn'. Since the transfer can come and go over the life time of the connection it thus becomes important to always set the correct "current transfer" when calling nghttp2 so that it doesn't get the *old* transfer that previously used the connection.
Diffstat (limited to 'lib/http.c')
-rw-r--r--lib/http.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/http.c b/lib/http.c
index 40773e6da..af479c8d0 100644
--- a/lib/http.c
+++ b/lib/http.c
@@ -3155,7 +3155,7 @@ CURLcode Curl_http(struct Curl_easy *data, bool *done)
(data->set.httpversion == CURL_HTTP_VERSION_2)) {
/* append HTTP2 upgrade magic stuff to the HTTP request if it isn't done
over SSL */
- result = Curl_http2_request_upgrade(&req, conn);
+ result = Curl_http2_request_upgrade(&req, data);
if(result) {
Curl_dyn_free(&req);
return result;