mirror of
https://github.com/MariaDB/server.git
synced 2025-01-22 14:54:20 +01:00
Closes #1969 closes[t:1969] Fix assertion in round_to_page
git-svn-id: file:///svn/toku/tokudb@14570 c7de825b-a66e-492c-adef-691d508d4ae1
This commit is contained in:
parent
191d616ee8
commit
a5cf59455a
1 changed files with 1 additions and 1 deletions
|
@ -42,7 +42,7 @@ round_to_page (size_t size) {
|
||||||
const size_t result = PAGE_SIZE+((size-1)&~(PAGE_SIZE-1));
|
const size_t result = PAGE_SIZE+((size-1)&~(PAGE_SIZE-1));
|
||||||
assert(0==(result&(PAGE_SIZE-1))); // make sure it's aligned
|
assert(0==(result&(PAGE_SIZE-1))); // make sure it's aligned
|
||||||
assert(result>=size); // make sure it's not too small
|
assert(result>=size); // make sure it's not too small
|
||||||
assert(size<result+PAGE_SIZE); // make sure we didn't grow by more than a page.
|
assert(result<size+PAGE_SIZE); // make sure we didn't grow by more than a page.
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue