Skip to content

Commit d2cae9c

Browse files
committed
fix ks_pid_t type overflow.
1 parent e4a7d8b commit d2cae9c

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/include/libks/ks_threadmutex.h

+4-1
Original file line numberDiff line numberDiff line change
@@ -43,9 +43,12 @@ typedef void *(*ks_thread_function_t) (ks_thread_t *, void *);
4343
#ifdef KS_PLAT_WIN
4444
typedef void * ks_thread_os_handle_t;
4545
typedef DWORD ks_pid_t;
46-
#else
46+
#elif KS_PLAT_LIN
4747
typedef pid_t ks_pid_t;
4848
typedef pthread_t ks_thread_os_handle_t;
49+
#else
50+
typedef uint64_t ks_pid_t;
51+
typedef pthread_t ks_thread_os_handle_t;
4952
#endif
5053

5154
typedef enum {

0 commit comments

Comments
 (0)