connect: only set connect timer on first socket

Only collect connect/appconnect timer stats on the first socket.

Fixes #22587
Closes #22592
Reported-by: GLaDOS-418 on github
This commit is contained in:
Stefan Eissing 2026-08-15 11:20:23 +02:00 committed by Daniel Stenberg
parent 91323de7f3
commit ebc0fbc0e8
No known key found for this signature in database
GPG key ID: 5CC908FDB71E12C2

View file

@ -309,7 +309,7 @@ static CURLcode conn_connect_trace(struct Curl_easy *data,
static void conn_report_connect_stats(struct Curl_cfilter *cf,
struct Curl_easy *data)
{
if(cf) {
if(cf && (cf->sockindex == FIRSTSOCKET)) {
struct curltime connected;
struct curltime appconnected;