gnunet-svn
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GNUnet-SVN] [gnurl] 126/153: curl_threads: silence bad-function-cast wa


From: gnunet
Subject: [GNUnet-SVN] [gnurl] 126/153: curl_threads: silence bad-function-cast warning
Date: Tue, 11 Sep 2018 12:53:17 +0200

This is an automated email from the git hooks/post-receive script.

ng0 pushed a commit to branch master
in repository gnurl.

commit edfaf5a25becd00e346d21bc6512de68056139f6
Author: Marcel Raad <address@hidden>
AuthorDate: Thu Aug 23 09:55:40 2018 +0200

    curl_threads: silence bad-function-cast warning
    
    As uintptr_t and HANDLE are always the same size, this warning is
    harmless. Just silence it using an intermediate uintptr_t variable.
    
    Closes https://github.com/curl/curl/pull/2908
---
 lib/curl_threads.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/curl_threads.c b/lib/curl_threads.c
index c1624a913..b8f0cd35d 100644
--- a/lib/curl_threads.c
+++ b/lib/curl_threads.c
@@ -108,7 +108,8 @@ curl_thread_t Curl_thread_create(unsigned int (CURL_STDCALL 
*func) (void *),
 #ifdef _WIN32_WCE
   t = CreateThread(NULL, 0, func, arg, 0, NULL);
 #else
-  t = (curl_thread_t)_beginthreadex(NULL, 0, func, arg, 0, NULL);
+  uintptr_t thread_handle = _beginthreadex(NULL, 0, func, arg, 0, NULL);
+  t = (curl_thread_t)thread_handle;
 #endif
   if((t == 0) || (t == LongToHandle(-1L))) {
 #ifdef _WIN32_WCE

-- 
To stop receiving notification emails like this one, please contact
address@hidden



reply via email to

[Prev in Thread] Current Thread [Next in Thread]