no set thread name on mingw
This commit is contained in:
parent
78a670e0c8
commit
6a7785d9d9
@ -37,24 +37,22 @@ namespace ix
|
|||||||
|
|
||||||
void SetThreadName(DWORD dwThreadID, const char* threadName)
|
void SetThreadName(DWORD dwThreadID, const char* threadName)
|
||||||
{
|
{
|
||||||
|
#ifndef __GNUC__
|
||||||
THREADNAME_INFO info;
|
THREADNAME_INFO info;
|
||||||
info.dwType = 0x1000;
|
info.dwType = 0x1000;
|
||||||
info.szName = threadName;
|
info.szName = threadName;
|
||||||
info.dwThreadID = dwThreadID;
|
info.dwThreadID = dwThreadID;
|
||||||
info.dwFlags = 0;
|
info.dwFlags = 0;
|
||||||
|
|
||||||
#ifndef __GNUC__
|
|
||||||
__try
|
__try
|
||||||
{
|
{
|
||||||
#endif
|
|
||||||
RaiseException(
|
RaiseException(
|
||||||
MS_VC_EXCEPTION, 0, sizeof(info) / sizeof(ULONG_PTR), (ULONG_PTR*) &info);
|
MS_VC_EXCEPTION, 0, sizeof(info) / sizeof(ULONG_PTR), (ULONG_PTR*) &info);
|
||||||
}
|
}
|
||||||
#ifndef __GNUC__
|
|
||||||
__except (EXCEPTION_EXECUTE_HANDLER)
|
__except (EXCEPTION_EXECUTE_HANDLER)
|
||||||
#endif
|
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user