mirror of
https://github.com/jemalloc/jemalloc.git
synced 2026-08-25 00:23:33 +03:00
Refactor (MALLOCX_ARENA_MAX + 1) to be MALLOCX_ARENA_LIMIT.
This resolves #673.
This commit is contained in:
parent
909f0482e4
commit
18a83681cf
5 changed files with 11 additions and 11 deletions
|
|
@ -13,10 +13,10 @@ extent_arena_get(const extent_t *extent) {
|
|||
* The following check is omitted because we should never actually read
|
||||
* a NULL arena pointer.
|
||||
*/
|
||||
if (false && arena_ind > MALLOCX_ARENA_MAX) {
|
||||
if (false && arena_ind >= MALLOCX_ARENA_LIMIT) {
|
||||
return NULL;
|
||||
}
|
||||
assert(arena_ind <= MALLOCX_ARENA_MAX);
|
||||
assert(arena_ind < MALLOCX_ARENA_LIMIT);
|
||||
return (arena_t *)atomic_load_p(&arenas[arena_ind], ATOMIC_ACQUIRE);
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue