diff options
author | Stefan Eissing <stefan@eissing.org> | 2023-01-06 12:33:34 +0100 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2023-01-09 13:23:20 +0100 |
commit | 1c5d8acf79efcf40ba20a232c4133fc81700c809 (patch) | |
tree | 512e2f011ab72fe8ffb37ccc92c25b5638f4073f /lib/cf-socket.c | |
parent | 0ef29268819b7a6d7c72d8f19bc6ad9e91d9b191 (diff) | |
download | curl-1c5d8acf79efcf40ba20a232c4133fc81700c809.tar.gz |
quic: improve connect error message, debugging info, fix false connect report
- ECONNECTREFUSED has not its own fail message in quic filters
- Debug logging in connect eyballing improved
- Fix bug in ngtcp2/quiche that could lead to false success reporting.
Reported-by: Divy Le Ray
Fixes #10245
Closes #10248
Diffstat (limited to 'lib/cf-socket.c')
-rw-r--r-- | lib/cf-socket.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/lib/cf-socket.c b/lib/cf-socket.c index df292d7b1..356b3657a 100644 --- a/lib/cf-socket.c +++ b/lib/cf-socket.c @@ -1555,10 +1555,14 @@ CURLcode Curl_cf_socket_peek(struct Curl_cfilter *cf, if(Curl_cf_is_socket(cf) && cf->ctx) { struct cf_socket_ctx *ctx = cf->ctx; - *psock = ctx->sock; - *paddr = &ctx->addr; - *premote_ip_str = ctx->r_ip; - *premote_port = ctx->r_port; + if(psock) + *psock = ctx->sock; + if(paddr) + *paddr = &ctx->addr; + if(premote_ip_str) + *premote_ip_str = ctx->r_ip; + if(premote_port) + *premote_port = ctx->r_port; return CURLE_OK; } return CURLE_FAILED_INIT; |