--- a/vendor/adb/sysdeps_win32.cpp +++ b/vendor/adb/sysdeps_win32.cpp @@ -3089,13 +3089,13 @@ } // The SetThreadDescription API was brought in version 1607 of Windows 10. -typedef HRESULT(WINAPI* SetThreadDescription)(HANDLE hThread, PCWSTR lpThreadDescription); +typedef HRESULT(WINAPI* SetThreadDescriptionFunc)(HANDLE hThread, PCWSTR lpThreadDescription); // Based on PlatformThread::SetName() from // https://cs.chromium.org/chromium/src/base/threading/platform_thread_win.cc int adb_thread_setname(const std::string& name) { // The SetThreadDescription API works even if no debugger is attached. - auto set_thread_description_func = reinterpret_cast( + auto set_thread_description_func = reinterpret_cast( ::GetProcAddress(::GetModuleHandleW(L"Kernel32.dll"), "SetThreadDescription")); if (set_thread_description_func) { std::wstring name_wide;