Thread: Re-add pthread_np.h include for FreeBSD/OpenBSD

Was a regression from #45315.

Fixes #46998.
This commit is contained in:
Rémi Verschelde 2021-03-14 22:42:41 +01:00
parent b060ca680a
commit 7a64819c2f
No known key found for this signature in database
GPG key ID: C3336907360768E1

View file

@ -35,6 +35,10 @@
#include "core/os/thread.h" #include "core/os/thread.h"
#include "core/string/ustring.h" #include "core/string/ustring.h"
#ifdef PTHREAD_BSD_SET_NAME
#include <pthread_np.h>
#endif
static Error set_name(const String &p_name) { static Error set_name(const String &p_name) {
#ifdef PTHREAD_NO_RENAME #ifdef PTHREAD_NO_RENAME
return ERR_UNAVAILABLE; return ERR_UNAVAILABLE;