summaryrefslogtreecommitdiff
path: root/devel/nspr/files/patch-bug301986
blob: cae4712dace7cd31d07f4c9154d9f3ceb32467b7 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
pthread_t can well be a 64-bit value -- on FreeBSD/amd64, for example.
Better to just keep calling it pthread_t isntead of casting to anything.

	-mi

--- pr/include/private/pprthred.h.orig	2018-08-28 12:42:28 UTC
+++ pr/include/private/pprthred.h
@@ -11,6 +11,7 @@
 ** developers only.
 */
 #include "nspr.h"
+#include <pthread.h>
 
 #if defined(XP_OS2)
 #define INCL_DOS
@@ -59,7 +60,7 @@ NSPR_API(void) PR_DetachThread(void);
 ** Get the id of the named thread. Each thread is assigned a unique id
 ** when it is created or attached.
 */
-NSPR_API(PRUint32) PR_GetThreadID(PRThread *thread);
+NSPR_API(pthread_t) PR_GetThreadID(PRThread *thread);
 
 /*
 ** Set the procedure that is called when a thread is dumped. The procedure
--- pr/src/pthreads/ptthread.c.orig	2018-08-28 12:42:28 UTC
+++ pr/src/pthreads/ptthread.c
@@ -1138,9 +1138,9 @@ PR_IMPLEMENT(void) PR_ProcessExit(PRIntn status)
     _exit(status);
 }
 
-PR_IMPLEMENT(PRUint32) PR_GetThreadID(PRThread *thred)
+PR_IMPLEMENT(pthread_t) PR_GetThreadID(PRThread *thred)
 {
-    return (PRUint32)thred->id;  /* and I don't know what they will do with it */
+    return thred->id;  /* and I don't know what they will do with it */
 }
 
 /*