mirror of
https://github.com/Mauler125/r5sdk.git
synced 2025-02-09 19:15:03 +01:00
Since this file no longer gets build along with the DLL project, but as a static lib instead, the 'DEDICATED' define no longer worked, and therefore this became broken after the CMake port. The 'CURLHandleError' helper function now takes a bool determining whether or not to log the error, and the caller disables it for dedicated (dedicated should only log the error once, this happens from within the caller class).
17 lines
643 B
C
17 lines
643 B
C
#ifndef TIER2_CURLUTILS_H
|
|
#define TIER2_CURLUTILS_H
|
|
|
|
extern ConVar* ssl_verify_peer;
|
|
extern ConVar* curl_timeout;
|
|
extern ConVar* curl_debug;
|
|
|
|
size_t CURLWriteStringCallback(char* contents, const size_t size, const size_t nmemb, void* userp);
|
|
|
|
CURL* CURLInitRequest(const char* remote, const char* request, string& outResponse, curl_slist*& slist);
|
|
CURLcode CURLSubmitRequest(CURL* curl, curl_slist*& slist);
|
|
CURLINFO CURLRetrieveInfo(CURL* curl);
|
|
|
|
bool CURLHandleError(CURL* curl, const CURLcode res, string& outMessage, const bool logError);
|
|
void CURLFormatUrl(string& outUrl, const char* host, const char* api);
|
|
|
|
#endif // !TIER2_CURLUTILS_H
|