diff options
Diffstat (limited to 'adb/sysdeps.h')
-rw-r--r-- | adb/sysdeps.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/adb/sysdeps.h b/adb/sysdeps.h index ba4306f..11de548 100644 --- a/adb/sysdeps.h +++ b/adb/sysdeps.h @@ -76,6 +76,11 @@ static __inline__ int adb_thread_create( adb_thread_t *thread, adb_thread_func return 0; } +static __inline__ unsigned long adb_thread_id() +{ + return GetCurrentThreadId(); +} + static __inline__ void close_on_exec(int fd) { /* nothing really */ @@ -515,6 +520,12 @@ static __inline__ char* adb_strtok_r(char *str, const char *delim, char **savep { return strtok_r(str, delim, saveptr); } + +static __inline__ unsigned long adb_thread_id() +{ + return (unsigned long)pthread_self(); +} + #undef strtok_r #define strtok_r ___xxx_strtok_r |