mirror of
https://github.com/jemalloc/jemalloc.git
synced 2026-06-06 04:04:17 +03:00
Switch ctl to explicitly use tsd instead of tsdn.
This commit is contained in:
parent
425463a446
commit
57beeb2fcb
3 changed files with 24 additions and 26 deletions
|
|
@ -2918,16 +2918,15 @@ je_mallctl(const char *name, void *oldp, size_t *oldlenp, void *newp,
|
|||
JEMALLOC_EXPORT int JEMALLOC_NOTHROW
|
||||
je_mallctlnametomib(const char *name, size_t *mibp, size_t *miblenp) {
|
||||
int ret;
|
||||
tsdn_t *tsdn;
|
||||
|
||||
if (unlikely(malloc_init())) {
|
||||
return EAGAIN;
|
||||
}
|
||||
|
||||
tsdn = tsdn_fetch();
|
||||
check_entry_exit_locking(tsdn);
|
||||
ret = ctl_nametomib(tsdn, name, mibp, miblenp);
|
||||
check_entry_exit_locking(tsdn);
|
||||
tsd_t *tsd = tsd_fetch();
|
||||
check_entry_exit_locking(tsd_tsdn(tsd));
|
||||
ret = ctl_nametomib(tsd, name, mibp, miblenp);
|
||||
check_entry_exit_locking(tsd_tsdn(tsd));
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue