diff options
| author | Anthony J. Bentley <anthony@anjbe.name> | 2016-07-17 04:09:46 -0600 |
|---|---|---|
| committer | Anthony J. Bentley <anthony@anjbe.name> | 2016-07-17 04:09:46 -0600 |
| commit | 64fb96e4934c7ab36acda84bdd8c36b2363e48e8 (patch) | |
| tree | 3eb698ea1d2dcb08a6e38d4b9969f94849133c95 /Source/Core/Common/Thread.cpp | |
| parent | 5c907386384666f1afc78d847b7bf88e86a49e1d (diff) | |
OpenBSD uses pthread_set_name_np() to set the name of a thread.
Diffstat (limited to 'Source/Core/Common/Thread.cpp')
| -rw-r--r-- | Source/Core/Common/Thread.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/Source/Core/Common/Thread.cpp b/Source/Core/Common/Thread.cpp index 557cbfbef2..a03b9c2e57 100644 --- a/Source/Core/Common/Thread.cpp +++ b/Source/Core/Common/Thread.cpp @@ -12,7 +12,7 @@ #ifdef __APPLE__ #include <mach/mach.h> -#elif defined BSD4_4 || defined __FreeBSD__ +#elif defined BSD4_4 || defined __FreeBSD__ || defined __OpenBSD__ #include <pthread_np.h> #endif @@ -132,7 +132,7 @@ void SetCurrentThreadName(const char* szThreadName) { #ifdef __APPLE__ pthread_setname_np(szThreadName); -#elif defined __FreeBSD__ +#elif defined __FreeBSD__ || defined __OpenBSD__ pthread_set_name_np(pthread_self(), szThreadName); #else // linux doesn't allow to set more than 16 bytes, including \0. |
