diff options
author | pfg <pfg@FreeBSD.org> | 2016-04-20 01:21:39 +0000 |
---|---|---|
committer | pfg <pfg@FreeBSD.org> | 2016-04-20 01:21:39 +0000 |
commit | 7ce919789adf84fa6f5faf5c751276f3544d0992 (patch) | |
tree | 1485c6e0f8a0235187c9f88de7fe4501ff9c88f1 /lib/libc/db | |
parent | a83d88847ec6776630c3b69efb8c6dcc2960f1bc (diff) | |
download | FreeBSD-src-7ce919789adf84fa6f5faf5c751276f3544d0992.zip FreeBSD-src-7ce919789adf84fa6f5faf5c751276f3544d0992.tar.gz |
libc: use our roundup2/rounddown2() macros when param.h is available.
rounddown2 tends to produce longer lines than the original code but
still it makes the code more readable.
Diffstat (limited to 'lib/libc/db')
-rw-r--r-- | lib/libc/db/hash/hash_page.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/libc/db/hash/hash_page.c b/lib/libc/db/hash/hash_page.c index 8040419..a2bb7cf 100644 --- a/lib/libc/db/hash/hash_page.c +++ b/lib/libc/db/hash/hash_page.c @@ -677,7 +677,7 @@ overflow_page(HTAB *hashp) bit = hashp->LAST_FREED & ((hashp->BSIZE << BYTE_SHIFT) - 1); j = bit / BITS_PER_MAP; - bit = bit & ~(BITS_PER_MAP - 1); + bit = rounddown2(bit, BITS_PER_MAP); } else { bit = 0; j = 0; |