all: remove FIXME and TODO comments
We can always improve. These comments tend to linger and go misleading or plain wrong over time. Closes #16283
This commit is contained in:
parent
f1d1c98b7f
commit
94c596bbc5
@ -660,7 +660,6 @@ static CURLcode cf_h1_proxy_connect(struct Curl_cfilter *cf,
|
|||||||
cf->ctx = ts;
|
cf->ctx = ts;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* TODO: can we do blocking? */
|
|
||||||
/* We want "seamless" operations through HTTP proxy tunnel */
|
/* We want "seamless" operations through HTTP proxy tunnel */
|
||||||
|
|
||||||
result = H1_CONNECT(cf, data, ts);
|
result = H1_CONNECT(cf, data, ts);
|
||||||
|
|||||||
@ -1408,7 +1408,7 @@ static ssize_t cf_h2_proxy_send(struct Curl_cfilter *cf,
|
|||||||
ssize_t nwritten;
|
ssize_t nwritten;
|
||||||
CURLcode result;
|
CURLcode result;
|
||||||
|
|
||||||
(void)eos; /* TODO, maybe useful for blocks? */
|
(void)eos;
|
||||||
if(ctx->tunnel.state != H2_TUNNEL_ESTABLISHED) {
|
if(ctx->tunnel.state != H2_TUNNEL_ESTABLISHED) {
|
||||||
*err = CURLE_SEND_ERROR;
|
*err = CURLE_SEND_ERROR;
|
||||||
return -1;
|
return -1;
|
||||||
|
|||||||
@ -696,7 +696,6 @@ CURLcode Curl_cf_https_setup(struct Curl_easy *data,
|
|||||||
break;
|
break;
|
||||||
case CURL_HTTP_VERSION_3:
|
case CURL_HTTP_VERSION_3:
|
||||||
/* We assume that silently not even trying H3 is ok here */
|
/* We assume that silently not even trying H3 is ok here */
|
||||||
/* TODO: should we fail instead? */
|
|
||||||
if(Curl_conn_may_http3(data, conn) == CURLE_OK)
|
if(Curl_conn_may_http3(data, conn) == CURLE_OK)
|
||||||
alpn_ids[alpn_count++] = ALPN_h3;
|
alpn_ids[alpn_count++] = ALPN_h3;
|
||||||
alpn_ids[alpn_count++] = ALPN_h2;
|
alpn_ids[alpn_count++] = ALPN_h2;
|
||||||
|
|||||||
@ -1325,7 +1325,6 @@ static CURLcode cf_tcp_connect(struct Curl_cfilter *cf,
|
|||||||
return CURLE_OK;
|
return CURLE_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* TODO: need to support blocking connect? */
|
|
||||||
if(blocking)
|
if(blocking)
|
||||||
return CURLE_UNSUPPORTED_PROTOCOL;
|
return CURLE_UNSUPPORTED_PROTOCOL;
|
||||||
|
|
||||||
@ -1432,7 +1431,7 @@ static void cf_socket_adjust_pollset(struct Curl_cfilter *cf,
|
|||||||
/* A listening socket filter needs to be connected before the accept
|
/* A listening socket filter needs to be connected before the accept
|
||||||
* for some weird FTP interaction. This should be rewritten, so that
|
* for some weird FTP interaction. This should be rewritten, so that
|
||||||
* FTP no longer does the socket checks and accept calls and delegates
|
* FTP no longer does the socket checks and accept calls and delegates
|
||||||
* all that to the filter. TODO. */
|
* all that to the filter. */
|
||||||
if(ctx->listening) {
|
if(ctx->listening) {
|
||||||
Curl_pollset_set_in_only(data, ps, ctx->sock);
|
Curl_pollset_set_in_only(data, ps, ctx->sock);
|
||||||
CURL_TRC_CF(data, cf, "adjust_pollset, listening, POLLIN fd=%"
|
CURL_TRC_CF(data, cf, "adjust_pollset, listening, POLLIN fd=%"
|
||||||
@ -1850,7 +1849,7 @@ static CURLcode cf_udp_setup_quic(struct Curl_cfilter *cf,
|
|||||||
/* QUIC needs a connected socket, nonblocking */
|
/* QUIC needs a connected socket, nonblocking */
|
||||||
DEBUGASSERT(ctx->sock != CURL_SOCKET_BAD);
|
DEBUGASSERT(ctx->sock != CURL_SOCKET_BAD);
|
||||||
|
|
||||||
rc = connect(ctx->sock, &ctx->addr.curl_sa_addr, /* NOLINT FIXME */
|
rc = connect(ctx->sock, &ctx->addr.curl_sa_addr, /* NOLINT */
|
||||||
(curl_socklen_t)ctx->addr.addrlen);
|
(curl_socklen_t)ctx->addr.addrlen);
|
||||||
if(-1 == rc) {
|
if(-1 == rc) {
|
||||||
return socket_connect_result(data, ctx->ip.remote_ip, SOCKERRNO);
|
return socket_connect_result(data, ctx->ip.remote_ip, SOCKERRNO);
|
||||||
@ -2213,7 +2212,7 @@ struct Curl_cftype Curl_cft_tcp_accept = {
|
|||||||
cf_tcp_accept_connect,
|
cf_tcp_accept_connect,
|
||||||
cf_socket_close,
|
cf_socket_close,
|
||||||
cf_socket_shutdown,
|
cf_socket_shutdown,
|
||||||
cf_socket_get_host, /* TODO: not accurate */
|
cf_socket_get_host,
|
||||||
cf_socket_adjust_pollset,
|
cf_socket_adjust_pollset,
|
||||||
cf_socket_data_pending,
|
cf_socket_data_pending,
|
||||||
cf_socket_send,
|
cf_socket_send,
|
||||||
|
|||||||
@ -166,11 +166,11 @@ int Curl_cpool_init(struct cpool *cpool,
|
|||||||
if(!cpool->idata)
|
if(!cpool->idata)
|
||||||
return 1; /* bad */
|
return 1; /* bad */
|
||||||
cpool->idata->state.internal = TRUE;
|
cpool->idata->state.internal = TRUE;
|
||||||
/* TODO: this is quirky. We need an internal handle for certain
|
/* This is quirky. We need an internal handle for certain operations, but we
|
||||||
* operations, but we do not add it to the multi (if there is one).
|
* do not add it to the multi (if there is one). We give it the multi so
|
||||||
* But we give it the multi so that socket event operations can work.
|
* that socket event operations can work. Probably better to have an
|
||||||
* Probably better to have an internal handle owned by the multi that
|
* internal handle owned by the multi that can be used for cpool
|
||||||
* can be used for cpool operations. */
|
* operations. */
|
||||||
cpool->idata->multi = multi;
|
cpool->idata->multi = multi;
|
||||||
#ifdef DEBUGBUILD
|
#ifdef DEBUGBUILD
|
||||||
if(getenv("CURL_DEBUG"))
|
if(getenv("CURL_DEBUG"))
|
||||||
@ -1302,7 +1302,6 @@ static int conn_upkeep(struct Curl_easy *data,
|
|||||||
void *param)
|
void *param)
|
||||||
{
|
{
|
||||||
struct curltime *now = param;
|
struct curltime *now = param;
|
||||||
/* TODO, shall we reap connections that return an error here? */
|
|
||||||
Curl_conn_upkeep(data, conn, now);
|
Curl_conn_upkeep(data, conn, now);
|
||||||
return 0; /* continue iteration */
|
return 0; /* continue iteration */
|
||||||
}
|
}
|
||||||
|
|||||||
@ -958,7 +958,7 @@ static CURLcode cf_he_connect(struct Curl_cfilter *cf,
|
|||||||
return CURLE_OK;
|
return CURLE_OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
(void)blocking; /* TODO: do we want to support this? */
|
(void)blocking;
|
||||||
DEBUGASSERT(ctx);
|
DEBUGASSERT(ctx);
|
||||||
*done = FALSE;
|
*done = FALSE;
|
||||||
|
|
||||||
|
|||||||
10
lib/http.c
10
lib/http.c
@ -495,7 +495,6 @@ static CURLcode http_perhapsrewind(struct Curl_easy *data,
|
|||||||
ongoing_auth ? " send, " : "");
|
ongoing_auth ? " send, " : "");
|
||||||
/* We decided to abort the ongoing transfer */
|
/* We decided to abort the ongoing transfer */
|
||||||
streamclose(conn, "Mid-auth HTTP and much data left to send");
|
streamclose(conn, "Mid-auth HTTP and much data left to send");
|
||||||
/* FIXME: questionable manipulation here, can we do this differently? */
|
|
||||||
data->req.size = 0; /* do not download any more than 0 bytes */
|
data->req.size = 0; /* do not download any more than 0 bytes */
|
||||||
}
|
}
|
||||||
return CURLE_OK;
|
return CURLE_OK;
|
||||||
@ -2477,7 +2476,7 @@ static CURLcode http_range(struct Curl_easy *data,
|
|||||||
}
|
}
|
||||||
else if(data->state.resume_from) {
|
else if(data->state.resume_from) {
|
||||||
/* This is because "resume" was selected */
|
/* This is because "resume" was selected */
|
||||||
/* TODO: not sure if we want to send this header during authentication
|
/* Not sure if we want to send this header during authentication
|
||||||
* negotiation, but test1084 checks for it. In which case we have a
|
* negotiation, but test1084 checks for it. In which case we have a
|
||||||
* "null" client reader installed that gives an unexpected length. */
|
* "null" client reader installed that gives an unexpected length. */
|
||||||
curl_off_t total_len = data->req.authneg ?
|
curl_off_t total_len = data->req.authneg ?
|
||||||
@ -3597,10 +3596,9 @@ static CURLcode http_on_response(struct Curl_easy *data,
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
else {
|
else {
|
||||||
/* We silently accept this as the final response.
|
/* We silently accept this as the final response. What are we
|
||||||
* TODO: this looks, uhm, wrong. What are we switching to if we
|
* switching to if we did not ask for an Upgrade? Maybe the
|
||||||
* did not ask for an Upgrade? Maybe the application provided an
|
* application provided an `Upgrade: xxx` header? */
|
||||||
* `Upgrade: xxx` header? */
|
|
||||||
k->header = FALSE;
|
k->header = FALSE;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
|||||||
@ -167,8 +167,6 @@ static CURLcode start_req(struct h1_req_parser *parser,
|
|||||||
if(!target_len || !hv_len)
|
if(!target_len || !hv_len)
|
||||||
goto out;
|
goto out;
|
||||||
|
|
||||||
/* TODO: we do not check HTTP_VERSION for conformity, should
|
|
||||||
+ do that when STRICT option is supplied. */
|
|
||||||
(void)hv;
|
(void)hv;
|
||||||
|
|
||||||
/* The TARGET can be (rfc 9112, ch. 3.2):
|
/* The TARGET can be (rfc 9112, ch. 3.2):
|
||||||
|
|||||||
@ -1598,8 +1598,8 @@ size_t Curl_mime_read(char *buffer, size_t size, size_t nitems, void *instream)
|
|||||||
|
|
||||||
(void) size; /* Always 1. */
|
(void) size; /* Always 1. */
|
||||||
|
|
||||||
/* TODO: this loop is broken. If `nitems` is <= 4, some encoders will
|
/* If `nitems` is <= 4, some encoders will return STOP_FILLING without
|
||||||
* return STOP_FILLING without adding any data and this loops infinitely. */
|
* adding any data and this loops infinitely. */
|
||||||
do {
|
do {
|
||||||
hasread = FALSE;
|
hasread = FALSE;
|
||||||
ret = readback_part(part, buffer, nitems, &hasread);
|
ret = readback_part(part, buffer, nitems, &hasread);
|
||||||
|
|||||||
@ -601,8 +601,8 @@ static CURLcode setopt_long(struct Curl_easy *data, CURLoption option,
|
|||||||
switch(arg) {
|
switch(arg) {
|
||||||
case CURL_HTTP_VERSION_NONE:
|
case CURL_HTTP_VERSION_NONE:
|
||||||
#ifdef USE_HTTP2
|
#ifdef USE_HTTP2
|
||||||
/* TODO: this seems an undesirable quirk to force a behaviour on
|
/* This seems an undesirable quirk to force a behaviour on lower
|
||||||
* lower implementations that they should recognize independently? */
|
* implementations that they should recognize independently? */
|
||||||
arg = CURL_HTTP_VERSION_2TLS;
|
arg = CURL_HTTP_VERSION_2TLS;
|
||||||
#endif
|
#endif
|
||||||
/* accepted */
|
/* accepted */
|
||||||
|
|||||||
@ -1552,10 +1552,9 @@ static CURLcode telnet_do(struct Curl_easy *data, bool *done)
|
|||||||
/* returned not-zero, this an error */
|
/* returned not-zero, this an error */
|
||||||
if(result) {
|
if(result) {
|
||||||
keepon = FALSE;
|
keepon = FALSE;
|
||||||
/* TODO: in test 1452, macOS sees a ECONNRESET sometimes?
|
/* In test 1452, macOS sees a ECONNRESET sometimes? Is this the
|
||||||
* Is this the telnet test server not shutting down the socket
|
* telnet test server not shutting down the socket in a clean way?
|
||||||
* in a clean way? Seems to be timing related, happens more
|
* Seems to be timing related, happens more on slow debug build */
|
||||||
* on slow debug build */
|
|
||||||
if(data->state.os_errno == ECONNRESET) {
|
if(data->state.os_errno == ECONNRESET) {
|
||||||
DEBUGF(infof(data, "telnet_do, unexpected ECONNRESET on recv"));
|
DEBUGF(infof(data, "telnet_do, unexpected ECONNRESET on recv"));
|
||||||
}
|
}
|
||||||
|
|||||||
@ -3212,7 +3212,7 @@ static CURLcode resolve_server(struct Curl_easy *data,
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
if(unix_path) {
|
if(unix_path) {
|
||||||
/* TODO, this only works if previous transport is TRNSPRT_TCP. Check it? */
|
/* This only works if previous transport is TRNSPRT_TCP. Check it? */
|
||||||
conn->transport = TRNSPRT_UNIX;
|
conn->transport = TRNSPRT_UNIX;
|
||||||
return resolve_unix(data, conn, unix_path);
|
return resolve_unix(data, conn, unix_path);
|
||||||
}
|
}
|
||||||
@ -3310,7 +3310,7 @@ static void reuse_conn(struct Curl_easy *data,
|
|||||||
* We want to reuse an existing conn to the remote endpoint.
|
* We want to reuse an existing conn to the remote endpoint.
|
||||||
* Since connection reuse does not match on conn->host necessarily, we
|
* Since connection reuse does not match on conn->host necessarily, we
|
||||||
* switch `existing` conn to `temp` conn's host settings.
|
* switch `existing` conn to `temp` conn's host settings.
|
||||||
* TODO: is this correct in the case of TLS connections that have
|
* Is this correct in the case of TLS connections that have
|
||||||
* used the original hostname in SNI to negotiate? Do we send
|
* used the original hostname in SNI to negotiate? Do we send
|
||||||
* requests for another host through the different SNI?
|
* requests for another host through the different SNI?
|
||||||
*/
|
*/
|
||||||
@ -3570,7 +3570,6 @@ static CURLcode create_conn(struct Curl_easy *data,
|
|||||||
if(result)
|
if(result)
|
||||||
goto out;
|
goto out;
|
||||||
|
|
||||||
/* FIXME: do we really want to run this every time we add a transfer? */
|
|
||||||
Curl_cpool_prune_dead(data);
|
Curl_cpool_prune_dead(data);
|
||||||
|
|
||||||
/*************************************************************
|
/*************************************************************
|
||||||
|
|||||||
@ -1108,7 +1108,6 @@ struct Curl_data_prio_node {
|
|||||||
/**
|
/**
|
||||||
* Priority information for an easy handle in relation to others
|
* Priority information for an easy handle in relation to others
|
||||||
* on the same connection.
|
* on the same connection.
|
||||||
* TODO: we need to adapt it to the new priority scheme as defined in RFC 9218
|
|
||||||
*/
|
*/
|
||||||
struct Curl_data_priority {
|
struct Curl_data_priority {
|
||||||
#ifdef USE_NGHTTP2
|
#ifdef USE_NGHTTP2
|
||||||
|
|||||||
@ -441,10 +441,10 @@ static bool MSH3_CALL msh3_data_received(MSH3_REQUEST *Request,
|
|||||||
CURLcode result;
|
CURLcode result;
|
||||||
bool rv = FALSE;
|
bool rv = FALSE;
|
||||||
|
|
||||||
/* TODO: we would like to limit the amount of data we are buffer here.
|
/* We would like to limit the amount of data we are buffer here. There seems
|
||||||
* There seems to be no mechanism in msh3 to adjust flow control and
|
* to be no mechanism in msh3 to adjust flow control and it is undocumented
|
||||||
* it is undocumented what happens if we return FALSE here or less
|
* what happens if we return FALSE here or less length (buflen is an inout
|
||||||
* length (buflen is an inout parameter).
|
* parameter).
|
||||||
*/
|
*/
|
||||||
(void)Request;
|
(void)Request;
|
||||||
if(!stream)
|
if(!stream)
|
||||||
@ -703,8 +703,8 @@ static ssize_t cf_msh3_send(struct Curl_cfilter *cf, struct Curl_easy *data,
|
|||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* TODO - msh3/msquic will hold onto this memory until the send complete
|
/* msh3/msquic will hold onto this memory until the send complete event.
|
||||||
event. How do we make sure curl does not free it until then? */
|
How do we make sure curl does not free it until then? */
|
||||||
*err = CURLE_OK;
|
*err = CURLE_OK;
|
||||||
nwritten = len;
|
nwritten = len;
|
||||||
}
|
}
|
||||||
@ -838,7 +838,7 @@ static CURLcode cf_connect_start(struct Curl_cfilter *cf,
|
|||||||
MSH3_SET_PORT(&addr, (uint16_t)cf->conn->remote_port);
|
MSH3_SET_PORT(&addr, (uint16_t)cf->conn->remote_port);
|
||||||
|
|
||||||
if(verify && (conn_config->CAfile || conn_config->CApath)) {
|
if(verify && (conn_config->CAfile || conn_config->CApath)) {
|
||||||
/* TODO: need a way to provide trust anchors to MSH3 */
|
/* Need a way to provide trust anchors to MSH3 */
|
||||||
#ifdef DEBUGBUILD
|
#ifdef DEBUGBUILD
|
||||||
/* we need this for our test cases to run */
|
/* we need this for our test cases to run */
|
||||||
CURL_TRC_CF(data, cf, "non-standard CA not supported, "
|
CURL_TRC_CF(data, cf, "non-standard CA not supported, "
|
||||||
@ -1006,7 +1006,7 @@ static CURLcode cf_msh3_query(struct Curl_cfilter *cf,
|
|||||||
|
|
||||||
switch(query) {
|
switch(query) {
|
||||||
case CF_QUERY_MAX_CONCURRENT: {
|
case CF_QUERY_MAX_CONCURRENT: {
|
||||||
/* TODO: we do not have access to this so far, fake it */
|
/* We do not have access to this so far, fake it */
|
||||||
(void)ctx;
|
(void)ctx;
|
||||||
*pres1 = 100;
|
*pres1 = 100;
|
||||||
return CURLE_OK;
|
return CURLE_OK;
|
||||||
@ -1091,7 +1091,7 @@ CURLcode Curl_cf_msh3_create(struct Curl_cfilter **pcf,
|
|||||||
|
|
||||||
(void)data;
|
(void)data;
|
||||||
(void)conn;
|
(void)conn;
|
||||||
(void)ai; /* TODO: msh3 resolves itself? */
|
(void)ai; /* msh3 resolves itself? */
|
||||||
ctx = calloc(1, sizeof(*ctx));
|
ctx = calloc(1, sizeof(*ctx));
|
||||||
if(!ctx) {
|
if(!ctx) {
|
||||||
result = CURLE_OUT_OF_MEMORY;
|
result = CURLE_OUT_OF_MEMORY;
|
||||||
|
|||||||
@ -394,7 +394,7 @@ static void quic_printf(void *user_data, const char *fmt, ...)
|
|||||||
struct Curl_cfilter *cf = user_data;
|
struct Curl_cfilter *cf = user_data;
|
||||||
struct cf_ngtcp2_ctx *ctx = cf->ctx;
|
struct cf_ngtcp2_ctx *ctx = cf->ctx;
|
||||||
|
|
||||||
(void)ctx; /* TODO: need an easy handle to infof() message */
|
(void)ctx; /* need an easy handle to infof() message */
|
||||||
va_list ap;
|
va_list ap;
|
||||||
va_start(ap, fmt);
|
va_start(ap, fmt);
|
||||||
vfprintf(stderr, fmt, ap);
|
vfprintf(stderr, fmt, ap);
|
||||||
@ -1591,7 +1591,7 @@ static ssize_t cf_ngtcp2_send(struct Curl_cfilter *cf, struct Curl_easy *data,
|
|||||||
if(ctx->tls_vrfy_result)
|
if(ctx->tls_vrfy_result)
|
||||||
return ctx->tls_vrfy_result;
|
return ctx->tls_vrfy_result;
|
||||||
|
|
||||||
(void)eos; /* TODO: use for stream EOF and block handling */
|
(void)eos; /* use for stream EOF and block handling */
|
||||||
result = cf_progress_ingress(cf, data, &pktx);
|
result = cf_progress_ingress(cf, data, &pktx);
|
||||||
if(result) {
|
if(result) {
|
||||||
*err = result;
|
*err = result;
|
||||||
@ -1965,8 +1965,8 @@ static CURLcode h3_data_pause(struct Curl_cfilter *cf,
|
|||||||
struct Curl_easy *data,
|
struct Curl_easy *data,
|
||||||
bool pause)
|
bool pause)
|
||||||
{
|
{
|
||||||
/* TODO: there seems right now no API in ngtcp2 to shrink/enlarge
|
/* There seems to exist no API in ngtcp2 to shrink/enlarge the streams
|
||||||
* the streams windows. As we do in HTTP/2. */
|
* windows. As we do in HTTP/2. */
|
||||||
if(!pause) {
|
if(!pause) {
|
||||||
h3_drain_stream(cf, data);
|
h3_drain_stream(cf, data);
|
||||||
Curl_expire(data, 0, EXPIRE_RUN_NOW);
|
Curl_expire(data, 0, EXPIRE_RUN_NOW);
|
||||||
|
|||||||
@ -1980,7 +1980,7 @@ static ssize_t cf_osslq_send(struct Curl_cfilter *cf, struct Curl_easy *data,
|
|||||||
ssize_t nwritten;
|
ssize_t nwritten;
|
||||||
CURLcode result;
|
CURLcode result;
|
||||||
|
|
||||||
(void)eos; /* TODO: use to end stream */
|
(void)eos; /* use to end stream */
|
||||||
CF_DATA_SAVE(save, cf, data);
|
CF_DATA_SAVE(save, cf, data);
|
||||||
DEBUGASSERT(cf->connected);
|
DEBUGASSERT(cf->connected);
|
||||||
DEBUGASSERT(ctx->tls.ossl.ssl);
|
DEBUGASSERT(ctx->tls.ossl.ssl);
|
||||||
|
|||||||
@ -926,8 +926,8 @@ static ssize_t cf_quiche_send_body(struct Curl_cfilter *cf,
|
|||||||
nwritten = quiche_h3_send_body(ctx->h3c, ctx->qconn, stream->id,
|
nwritten = quiche_h3_send_body(ctx->h3c, ctx->qconn, stream->id,
|
||||||
(uint8_t *)buf, len, eos);
|
(uint8_t *)buf, len, eos);
|
||||||
if(nwritten == QUICHE_H3_ERR_DONE || (nwritten == 0 && len > 0)) {
|
if(nwritten == QUICHE_H3_ERR_DONE || (nwritten == 0 && len > 0)) {
|
||||||
/* TODO: we seem to be blocked on flow control and should HOLD
|
/* Blocked on flow control and should HOLD sending. But when do we open
|
||||||
* sending. But when do we open again? */
|
* again? */
|
||||||
if(!quiche_conn_stream_writable(ctx->qconn, stream->id, len)) {
|
if(!quiche_conn_stream_writable(ctx->qconn, stream->id, len)) {
|
||||||
CURL_TRC_CF(data, cf, "[%" FMT_PRIu64 "] send_body(len=%zu) "
|
CURL_TRC_CF(data, cf, "[%" FMT_PRIu64 "] send_body(len=%zu) "
|
||||||
"-> window exhausted", stream->id, len);
|
"-> window exhausted", stream->id, len);
|
||||||
@ -1204,8 +1204,8 @@ static CURLcode h3_data_pause(struct Curl_cfilter *cf,
|
|||||||
struct Curl_easy *data,
|
struct Curl_easy *data,
|
||||||
bool pause)
|
bool pause)
|
||||||
{
|
{
|
||||||
/* TODO: there seems right now no API in quiche to shrink/enlarge
|
/* There seems to exist no API in quiche to shrink/enlarge the streams
|
||||||
* the streams windows. As we do in HTTP/2. */
|
* windows. As we do in HTTP/2. */
|
||||||
if(!pause) {
|
if(!pause) {
|
||||||
h3_drain_stream(cf, data);
|
h3_drain_stream(cf, data);
|
||||||
Curl_expire(data, 0, EXPIRE_RUN_NOW);
|
Curl_expire(data, 0, EXPIRE_RUN_NOW);
|
||||||
|
|||||||
@ -1633,7 +1633,6 @@ static CURLcode mbedtls_sha256sum(const unsigned char *input,
|
|||||||
unsigned char *sha256sum,
|
unsigned char *sha256sum,
|
||||||
size_t sha256len UNUSED_PARAM)
|
size_t sha256len UNUSED_PARAM)
|
||||||
{
|
{
|
||||||
/* TODO: explain this for different mbedtls 2.x vs 3 version */
|
|
||||||
(void)sha256len;
|
(void)sha256len;
|
||||||
#if MBEDTLS_VERSION_NUMBER < 0x02070000
|
#if MBEDTLS_VERSION_NUMBER < 0x02070000
|
||||||
mbedtls_sha256(input, inputlen, sha256sum, 0);
|
mbedtls_sha256(input, inputlen, sha256sum, 0);
|
||||||
|
|||||||
@ -2049,8 +2049,6 @@ static CURLcode ossl_set_provider(struct Curl_easy *data, const char *provider)
|
|||||||
sizeof(error_buffer)));
|
sizeof(error_buffer)));
|
||||||
/* Do not attempt to load it again */
|
/* Do not attempt to load it again */
|
||||||
data->state.provider_failed = TRUE;
|
data->state.provider_failed = TRUE;
|
||||||
/* FIXME not the right error but much less fuss than creating a new
|
|
||||||
* public one */
|
|
||||||
return CURLE_SSL_ENGINE_NOTFOUND;
|
return CURLE_SSL_ENGINE_NOTFOUND;
|
||||||
}
|
}
|
||||||
data->state.provider = TRUE;
|
data->state.provider = TRUE;
|
||||||
@ -4283,7 +4281,6 @@ static void ossl_trace_ech_retry_configs(struct Curl_easy *data, SSL* ssl,
|
|||||||
servername_type = SSL_get_servername_type(ssl);
|
servername_type = SSL_get_servername_type(ssl);
|
||||||
inner = SSL_get_servername(ssl, servername_type);
|
inner = SSL_get_servername(ssl, servername_type);
|
||||||
SSL_get0_ech_name_override(ssl, &outer, &out_name_len);
|
SSL_get0_ech_name_override(ssl, &outer, &out_name_len);
|
||||||
/* TODO: get the inner from BoringSSL */
|
|
||||||
infof(data, "ECH: retry_configs for %s from %s, %d %d",
|
infof(data, "ECH: retry_configs for %s from %s, %d %d",
|
||||||
inner ? inner : "NULL", outer ? outer : "NULL", reason, rv);
|
inner ? inner : "NULL", outer ? outer : "NULL", reason, rv);
|
||||||
#endif
|
#endif
|
||||||
|
|||||||
@ -2367,7 +2367,6 @@ static CURLcode schannel_shutdown(struct Curl_cfilter *cf,
|
|||||||
Curl_pSecFn->FreeContextBuffer(outbuf.pvBuffer);
|
Curl_pSecFn->FreeContextBuffer(outbuf.pvBuffer);
|
||||||
if(!result) {
|
if(!result) {
|
||||||
if(written < (ssize_t)outbuf.cbBuffer) {
|
if(written < (ssize_t)outbuf.cbBuffer) {
|
||||||
/* TODO: handle partial sends */
|
|
||||||
failf(data, "schannel: failed to send close msg: %s"
|
failf(data, "schannel: failed to send close msg: %s"
|
||||||
" (bytes written: %zd)", curl_easy_strerror(result), written);
|
" (bytes written: %zd)", curl_easy_strerror(result), written);
|
||||||
result = CURLE_SEND_ERROR;
|
result = CURLE_SEND_ERROR;
|
||||||
|
|||||||
@ -1941,8 +1941,8 @@ CURLcode Curl_alpn_set_negotiated(struct Curl_cfilter *cf,
|
|||||||
else {
|
else {
|
||||||
*palpn = CURL_HTTP_VERSION_NONE;
|
*palpn = CURL_HTTP_VERSION_NONE;
|
||||||
failf(data, "unsupported ALPN protocol: '%.*s'", (int)proto_len, proto);
|
failf(data, "unsupported ALPN protocol: '%.*s'", (int)proto_len, proto);
|
||||||
/* TODO: do we want to fail this? Previous code just ignored it and
|
/* Previous code just ignored it and some vtls backends even ignore the
|
||||||
* some vtls backends even ignore the return code of this function. */
|
* return code of this function. */
|
||||||
/* return CURLE_NOT_BUILT_IN; */
|
/* return CURLE_NOT_BUILT_IN; */
|
||||||
goto out;
|
goto out;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -586,9 +586,9 @@ static CURLcode post_per_transfer(struct GlobalConfig *global,
|
|||||||
* or close/re-open the file so that the next attempt starts
|
* or close/re-open the file so that the next attempt starts
|
||||||
* over from the beginning.
|
* over from the beginning.
|
||||||
*
|
*
|
||||||
* TODO: similar action for the upload case. We might need
|
* For the upload case, we might need to start over reading from a
|
||||||
* to start over reading from a previous point if we have
|
* previous point if we have uploaded something when this was
|
||||||
* uploaded something when this was returned.
|
* returned.
|
||||||
*/
|
*/
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -2040,9 +2040,9 @@ static CURLcode single_transfer(struct GlobalConfig *global,
|
|||||||
* the headers, we need to open it in append mode, since transfers
|
* the headers, we need to open it in append mode, since transfers
|
||||||
* might finish in any order.
|
* might finish in any order.
|
||||||
* The first transfer just clears the file.
|
* The first transfer just clears the file.
|
||||||
* TODO: Consider placing the file handle inside the
|
*
|
||||||
* OperationConfig, so that it does not need to be opened/closed
|
* Consider placing the file handle inside the OperationConfig, so
|
||||||
* for every transfer.
|
* that it does not need to be opened/closed for every transfer.
|
||||||
*/
|
*/
|
||||||
if(config->create_dirs) {
|
if(config->create_dirs) {
|
||||||
result = create_dir_hierarchy(config->headerfile, global);
|
result = create_dir_hierarchy(config->headerfile, global);
|
||||||
|
|||||||
@ -33,9 +33,6 @@
|
|||||||
* Read commands from FILE (set with --config). The commands control how to
|
* Read commands from FILE (set with --config). The commands control how to
|
||||||
* act and is reset to defaults each client TCP connect.
|
* act and is reset to defaults each client TCP connect.
|
||||||
*
|
*
|
||||||
* Config file keywords:
|
|
||||||
*
|
|
||||||
* TODO
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* based on sockfilt.c */
|
/* based on sockfilt.c */
|
||||||
@ -418,7 +415,7 @@ static int publish(FILE *dump,
|
|||||||
if(!packet)
|
if(!packet)
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
packet[0] = MQTT_MSG_PUBLISH; /* TODO: set QoS? */
|
packet[0] = MQTT_MSG_PUBLISH;
|
||||||
memcpy(&packet[1], rembuffer, encodedlen);
|
memcpy(&packet[1], rembuffer, encodedlen);
|
||||||
|
|
||||||
(void)packetid;
|
(void)packetid;
|
||||||
@ -684,10 +681,9 @@ static curl_socket_t mqttit(curl_socket_t fd)
|
|||||||
|
|
||||||
topiclen = (size_t)(buffer[1 + bytes] << 8) | buffer[2 + bytes];
|
topiclen = (size_t)(buffer[1 + bytes] << 8) | buffer[2 + bytes];
|
||||||
logmsg("Got %zu bytes topic", topiclen);
|
logmsg("Got %zu bytes topic", topiclen);
|
||||||
/* TODO: verify topiclen */
|
|
||||||
|
|
||||||
#ifdef QOS
|
#ifdef QOS
|
||||||
/* TODO: handle packetid if there is one. Send puback if QoS > 0 */
|
/* Handle packetid if there is one. Send puback if QoS > 0 */
|
||||||
puback(dump, fd, 0);
|
puback(dump, fd, 0);
|
||||||
#endif
|
#endif
|
||||||
/* expect a disconnect here */
|
/* expect a disconnect here */
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user