summaryrefslogtreecommitdiff
path: root/src/hook.c
diff options
context:
space:
mode:
authorQi Wang <interwq@gwu.edu>2022-05-06 11:28:25 -0700
committerQi Wang <interwq@gwu.edu>2022-05-06 11:28:25 -0700
commit54eaed1d8b56b1aa528be3bdd1877e59c56fa90c (patch)
treee79620e0c00b1f8b6b698fbe74df6bae7d812ae2 /src/hook.c
parentea6b3e973b477b8061e0076bb257dbd7f3faa756 (diff)
parent304c919829f9f340669b61fa64867cfe5dba8021 (diff)
downloadjemalloc-master.tar.gz
Merge branch 'dev'5.3.0master
Diffstat (limited to 'src/hook.c')
-rw-r--r--src/hook.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/hook.c b/src/hook.c
index 9ac703cf..493edbbe 100644
--- a/src/hook.c
+++ b/src/hook.c
@@ -130,9 +130,9 @@ hook_reentrantp() {
*/
static bool in_hook_global = true;
tsdn_t *tsdn = tsdn_fetch();
- tcache_t *tcache = tsdn_tcachep_get(tsdn);
- if (tcache != NULL) {
- return &tcache->in_hook;
+ bool *in_hook = tsdn_in_hookp_get(tsdn);
+ if (in_hook!= NULL) {
+ return in_hook;
}
return &in_hook_global;
}