summaryrefslogtreecommitdiffstats
path: root/contrib/libs/curl/lib/curl_threads.c
diff options
context:
space:
mode:
authorthegeorg <[email protected]>2024-10-11 21:07:18 +0300
committerthegeorg <[email protected]>2024-10-11 21:17:24 +0300
commit1df197e6035ea9826bfedee7d48812e318ba9c7a (patch)
tree76b8e9de41820755adf209854d06a84a8b5a1988 /contrib/libs/curl/lib/curl_threads.c
parentf9c007ea1b59b960201def74990810b26ecdfd48 (diff)
Revert "Update contrib/libs/curl to 8.10.1" to fix
Revert "Update contrib/libs/curl to 8.10.1" This reverts commit 428ef806a15515cdaa325530aa8cc6903fac5fb6, reversing changes made to 40e46e6394df409d1545a3771c8a47a86ed55eac. Revert "Fix formatting after rXXXXXX" This reverts commit a73689311a92e195d14136c5a0049ef1e40b1f3e, reversing changes made to 17980b8756d1f74d3dacddc7ca4945c30f35611c. commit_hash:5c5194831e5455b61fbee61619066396626beab1
Diffstat (limited to 'contrib/libs/curl/lib/curl_threads.c')
-rw-r--r--contrib/libs/curl/lib/curl_threads.c18
1 files changed, 5 insertions, 13 deletions
diff --git a/contrib/libs/curl/lib/curl_threads.c b/contrib/libs/curl/lib/curl_threads.c
index 6d73273f789..222d9364f03 100644
--- a/contrib/libs/curl/lib/curl_threads.c
+++ b/contrib/libs/curl/lib/curl_threads.c
@@ -35,9 +35,7 @@
#endif
#include "curl_threads.h"
-#ifdef BUILDING_LIBCURL
#include "curl_memory.h"
-#endif
/* The last #include file should be: */
#include "memdebug.h"
@@ -102,23 +100,18 @@ int Curl_thread_join(curl_thread_t *hnd)
#elif defined(USE_THREADS_WIN32)
-curl_thread_t Curl_thread_create(
-#if defined(_WIN32_WCE) || defined(CURL_WINDOWS_APP)
- DWORD
-#else
- unsigned int
-#endif
- (CURL_STDCALL *func) (void *),
+/* !checksrc! disable SPACEBEFOREPAREN 1 */
+curl_thread_t Curl_thread_create(unsigned int (CURL_STDCALL *func) (void *),
void *arg)
{
-#if defined(_WIN32_WCE) || defined(CURL_WINDOWS_APP)
+#ifdef _WIN32_WCE
typedef HANDLE curl_win_thread_handle_t;
#else
typedef uintptr_t curl_win_thread_handle_t;
#endif
curl_thread_t t;
curl_win_thread_handle_t thread_handle;
-#if defined(_WIN32_WCE) || defined(CURL_WINDOWS_APP)
+#ifdef _WIN32_WCE
thread_handle = CreateThread(NULL, 0, func, arg, 0, NULL);
#else
thread_handle = _beginthreadex(NULL, 0, func, arg, 0, NULL);
@@ -138,8 +131,7 @@ curl_thread_t Curl_thread_create(
void Curl_thread_destroy(curl_thread_t hnd)
{
- if(hnd != curl_thread_t_null)
- CloseHandle(hnd);
+ CloseHandle(hnd);
}
int Curl_thread_join(curl_thread_t *hnd)