[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [gnurl] 129/220: ngtcp2: Consume QUIC STREAM data properly
From: |
gnunet |
Subject: |
[GNUnet-SVN] [gnurl] 129/220: ngtcp2: Consume QUIC STREAM data properly |
Date: |
Thu, 12 Sep 2019 17:28:09 +0200 |
This is an automated email from the git hooks/post-receive script.
ng0 pushed a commit to branch master
in repository gnurl.
commit e42bd8a204e4db9320bf5b020c799b8e10b3b93d
Author: Tatsuhiro Tsujikawa <address@hidden>
AuthorDate: Thu Aug 15 14:52:09 2019 +0900
ngtcp2: Consume QUIC STREAM data properly
---
lib/vquic/ngtcp2.c | 21 +++++++++++++--------
1 file changed, 13 insertions(+), 8 deletions(-)
diff --git a/lib/vquic/ngtcp2.c b/lib/vquic/ngtcp2.c
index a2285e75e..c26e80670 100644
--- a/lib/vquic/ngtcp2.c
+++ b/lib/vquic/ngtcp2.c
@@ -859,8 +859,9 @@ static int cb_recv_stream_data(ngtcp2_conn *tconn, int64_t
stream_id,
return NGTCP2_ERR_CALLBACK_FAILURE;
}
- ngtcp2_conn_extend_max_stream_offset(tconn, stream_id, buflen);
- ngtcp2_conn_extend_max_offset(tconn, buflen);
+ ngtcp2_conn_extend_max_stream_offset(tconn, stream_id, nconsumed);
+ ngtcp2_conn_extend_max_offset(tconn, nconsumed);
+
return 0;
}
@@ -1229,12 +1230,11 @@ static int cb_h3_recv_data(nghttp3_conn *conn, int64_t
stream_id,
const uint8_t *buf, size_t buflen,
void *user_data, void *stream_user_data)
{
+ struct quicsocket *qs = user_data;
size_t ncopy;
struct Curl_easy *data = stream_user_data;
struct HTTP *stream = data->req.protop;
(void)conn;
- (void)stream_id;
- (void)user_data;
fprintf(stderr, "cb_h3_recv_data CALLED with %d bytes\n", buflen);
/* TODO: this needs to be handled properly */
@@ -1246,6 +1246,9 @@ static int cb_h3_recv_data(nghttp3_conn *conn, int64_t
stream_id,
stream->memlen += ncopy;
stream->mem += ncopy;
+ ngtcp2_conn_extend_max_stream_offset(qs->qconn, stream_id, buflen);
+ ngtcp2_conn_extend_max_offset(qs->qconn, buflen);
+
return 0;
}
@@ -1253,12 +1256,14 @@ static int cb_h3_deferred_consume(nghttp3_conn *conn,
int64_t stream_id,
size_t consumed, void *user_data,
void *stream_user_data)
{
+ struct quicsocket *qs = user_data;
(void)conn;
- (void)stream_id;
- (void)consumed;
- (void)user_data;
(void)stream_user_data;
fprintf(stderr, "cb_h3_deferred_consume CALLED\n");
+
+ ngtcp2_conn_extend_max_stream_offset(qs->qconn, stream_id, consumed);
+ ngtcp2_conn_extend_max_offset(qs->qconn, consumed);
+
return 0;
}
@@ -1394,7 +1399,7 @@ static int init_ngh3_conn(struct quicsocket *qs)
&ngh3_callbacks,
&qs->h3settings,
nghttp3_mem_default(),
- qs->conn->data);
+ qs);
if(rc) {
result = CURLE_OUT_OF_MEMORY;
goto fail;
--
To stop receiving notification emails like this one, please contact
address@hidden.
- [GNUnet-SVN] [gnurl] 131/220: ngtcp2: add missing nghttp3_conn_add_write_offset call, (continued)
- [GNUnet-SVN] [gnurl] 131/220: ngtcp2: add missing nghttp3_conn_add_write_offset call, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 132/220: ngtcp2: provide the callbacks as a static struct, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 85/220: curl: make use of CURLINFO_RETRY_AFTER when retrying, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 89/220: alt-svc: send Alt-Used: in redirected requests, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 141/220: vssh: move ssh init/cleanup functions into backend code, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 114/220: CURLOPT_ALTSVC_CTRL.3: remove CURLALTSVC_ALTUSED, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 120/220: curl_version_info: make the quic_version a const, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 126/220: connect: connections are persistent by default for HTTP/3, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 134/220: travis: reduce number of torture tests in 'coverage', gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 150/220: configure: use pkg-config to detect quiche, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 129/220: ngtcp2: Consume QUIC STREAM data properly,
gnunet <=
- [GNUnet-SVN] [gnurl] 137/220: travis: add a quiche build, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 149/220: CURLOPT_SSL_VERIFYHOST: treat the value 1 as 2, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 154/220: openssl: build warning free with boringssl, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 165/220: ngtcp2: use nghttp3_version(), gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 166/220: ngtcp2: improve h3 response receiving, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 136/220: http: fix use of credentials from URL when using HTTP proxy, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 155/220: spnego_sspi: add typecast to fix build warning, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 152/220: ngtcp2: make postfields-set posts work, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 162/220: http: the 'closed' struct field is used by both ngh2 and ngh3, gnunet, 2019/09/12
- [GNUnet-SVN] [gnurl] 164/220: ngtcp2: sync with upstream API changes, gnunet, 2019/09/12