mingw: squash another warning about a cast

MSys2's compiler is correct that casting a "void *" to a "DWORD" loses precision, but in the case of pthread_exit() we know that the value fits into a DWORD. Just like casting handles to DWORDs, let's work around this issue by casting to "intrptr_t" first, and immediately cast to the final type. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Johannes Schindelin committed Jan 15, 2016 at 14:24 UTC 83c90da3c145c7f39cb321a3d3db59c167abd572
1 file changed +1 -1
compat/win32/pthread.h
+1 -1
@@ -77,7 +77,7 @@ extern pthread_t pthread_self(void);
77
78 static inline int pthread_exit(void *ret)
79 {
80 - ExitThread((DWORD)ret);
80 + ExitThread((DWORD)(intptr_t)ret);
81 }
82
83 typedef DWORD pthread_key_t;