summaryrefslogtreecommitdiff
path: root/lib/getinfo.c
diff options
context:
space:
mode:
authorSeonah Moon <seonah1.moon@samsung.com>2024-01-02 20:07:54 +0900
committerSeonah Moon <seonah1.moon@samsung.com>2024-01-02 20:37:43 +0900
commitaf71747bfb8e0dfb8b2870e30d720ce10b839814 (patch)
treedfd86789c7a44fccf1847280213d4ff10e41cc06 /lib/getinfo.c
parentb16a7a56e08377965863acf50afb7d91f32ba995 (diff)
downloadcurl-upstream.tar.gz
curl-upstream.tar.bz2
curl-upstream.zip
Imported Upstream version 8.5.0upstream/8.5.0upstream
Change-Id: I8f77c680623836749aba616cecd0390fc34b0c3c
Diffstat (limited to 'lib/getinfo.c')
-rw-r--r--lib/getinfo.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/lib/getinfo.c b/lib/getinfo.c
index c3556b310..f1574e097 100644
--- a/lib/getinfo.c
+++ b/lib/getinfo.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2022, Daniel Stenberg, <daniel@haxx.se>, et al.
+ * Copyright (C) Daniel Stenberg, <daniel@haxx.se>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -415,6 +415,13 @@ static CURLcode getinfo_offt(struct Curl_easy *data, CURLINFO info,
case CURLINFO_RETRY_AFTER:
*param_offt = data->info.retry_after;
break;
+ case CURLINFO_XFER_ID:
+ *param_offt = data->id;
+ break;
+ case CURLINFO_CONN_ID:
+ *param_offt = data->conn?
+ data->conn->connection_id : data->state.recent_conn_id;
+ break;
default:
return CURLE_UNKNOWN_OPTION;
}
@@ -533,13 +540,7 @@ static CURLcode getinfo_slist(struct Curl_easy *data, CURLINFO info,
#ifdef USE_SSL
if(conn && tsi->backend != CURLSSLBACKEND_NONE) {
- unsigned int i;
- for(i = 0; i < (sizeof(conn->ssl) / sizeof(conn->ssl[0])); ++i) {
- if(conn->ssl[i].use) {
- tsi->internals = Curl_ssl->get_internals(&conn->ssl[i], info);
- break;
- }
- }
+ tsi->internals = Curl_ssl_get_internals(data, FIRSTSOCKET, info, 0);
}
#endif
}