add recursion guard to deferred callback

This commit is contained in:
daan 2019-09-09 08:02:41 -07:00
parent e227341f5b
commit 23155c5d71
4 changed files with 7 additions and 4 deletions

View file

@ -405,6 +405,7 @@ typedef struct mi_os_tld_s {
// Thread local data
struct mi_tld_s {
unsigned long long heartbeat; // monotonic heartbeat count
bool recurse; // true if deferred was called; used to prevent infinite recursion.
mi_heap_t* heap_backing; // backing heap of this thread (cannot be deleted)
mi_segments_tld_t segments; // segment tld
mi_os_tld_t os; // os tld