Fix arenas_cache_cleanup().
Fix arenas_cache_cleanup() to handle allocation/deallocation within the application's thread-specific data cleanup functions even after arenas_cache is torn down.
This commit is contained in:
committed by
Jason Evans
parent
b5c2a347d7
commit
45e9f66c28
@@ -649,8 +649,12 @@ arenas_cache_cleanup(tsd_t *tsd)
|
||||
arena_t **arenas_cache;
|
||||
|
||||
arenas_cache = tsd_arenas_cache_get(tsd);
|
||||
if (arenas_cache != NULL)
|
||||
if (arenas_cache != NULL) {
|
||||
bool *arenas_cache_bypassp = tsd_arenas_cache_bypassp_get(tsd);
|
||||
*arenas_cache_bypassp = true;
|
||||
tsd_arenas_cache_set(tsd, NULL);
|
||||
a0dalloc(arenas_cache);
|
||||
}
|
||||
}
|
||||
|
||||
void
|
||||
|
Reference in New Issue
Block a user