Windows: Fix missing cygwin thread ID
* Cygwin uses POSIX threads, not Windows threads
This commit is contained in:
parent
75b1cf81db
commit
1cc9c6087d
2 changed files with 5 additions and 1 deletions
|
@ -24,6 +24,8 @@
|
|||
# include <sys/syscall.h>
|
||||
#elif defined(__APPLE__)
|
||||
# include <mach/mach.h>
|
||||
#elif defined(__CYGWIN__)
|
||||
# include <windows.h>
|
||||
#endif
|
||||
|
||||
#ifdef _XOPEN_SOURCE
|
||||
|
@ -73,6 +75,8 @@ int usbi_get_tid(void)
|
|||
#elif defined(__APPLE__)
|
||||
ret = mach_thread_self();
|
||||
mach_port_deallocate(mach_task_self(), ret);
|
||||
#elif defined(__CYGWIN__)
|
||||
ret = GetCurrentThreadId();
|
||||
#endif
|
||||
/* TODO: NetBSD thread ID support */
|
||||
return ret;
|
||||
|
|
|
@ -1 +1 @@
|
|||
#define LIBUSB_NANO 10504
|
||||
#define LIBUSB_NANO 10505
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue