Merge pull request #359 from robertblaketaylor/master

Set thread init false on thread exit for manual lifetime cases
This commit is contained in:
Bartosz Taudul 2022-04-05 20:35:02 +02:00 committed by GitHub
commit fc473a0c9d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -14,6 +14,10 @@
namespace tracy namespace tracy
{ {
#ifdef TRACY_MANUAL_LIFETIME
extern thread_local bool RpThreadInitDone;
#endif
class ThreadExitHandler class ThreadExitHandler
{ {
public: public:
@ -21,6 +25,7 @@ public:
{ {
#ifdef TRACY_MANUAL_LIFETIME #ifdef TRACY_MANUAL_LIFETIME
rpmalloc_thread_finalize(); rpmalloc_thread_finalize();
RpThreadInitDone = false;
#endif #endif
} }
}; };