Skip to content

Commit e8dd205

Browse files
authored
Fix deprecated CURL API usage. (#1238)
1 parent bad56a0 commit e8dd205

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

lib/http/HttpClient_Curl.hpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,13 @@ class CurlHttpOperation {
208208
* Note that this API takes a pointer to a 'long' while we use
209209
* curl_socket_t for sockets otherwise.
210210
*/
211+
212+
#if LIBCURL_VERSION_NUM >= 0x072D00 // Version 7.45.00
213+
res = curl_easy_getinfo(curl, CURLINFO_ACTIVESOCKET, &sockextr);
214+
#else
211215
res = curl_easy_getinfo(curl, CURLINFO_LASTSOCKET, &sockextr);
216+
#endif
217+
212218
if(CURLE_OK != res)
213219
{
214220
DispatchEvent(OnConnectFailed); // couldn't connect - stage 2

0 commit comments

Comments
 (0)