Improve thread IDs to avoid collisions with threads not created by the Godot API.
This commit is contained in:
parent
05248535f7
commit
9887c2b4f0
2 changed files with 17 additions and 12 deletions
|
|
@ -62,9 +62,10 @@ private:
|
|||
friend class Main;
|
||||
|
||||
static ID main_thread_id;
|
||||
static SafeNumeric<Thread::ID> last_thread_id;
|
||||
|
||||
ID id = 0;
|
||||
static uint64_t _thread_id_hash(const std::thread::id &p_t);
|
||||
|
||||
ID id = _thread_id_hash(std::thread::id());
|
||||
static thread_local ID caller_id;
|
||||
std::thread thread;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue