1
Fork 0
mirror of git://git.sv.gnu.org/emacs.git synced 2026-03-26 16:51:46 -07:00

Using rangecheck rather than checking base and limit ourselves.

Copied from Perforce
 Change: 190447
 ServerID: perforce.ravenbrook.com
This commit is contained in:
Richard Brooksby 2016-03-27 12:48:58 +01:00
parent 463afcd812
commit ff39f2a8fb

View file

@ -75,12 +75,13 @@ static Bool CBSBlockCheck(CBSBlock block)
{
UNUSED(block); /* Required because there is no signature */
CHECKL(block != NULL);
/* Can't use CHECKD_NOSIG because TreeEMPTY is NULL. */
CHECKL(TreeCheck(cbsBlockTree(block)));
/* If the block is in the middle of being deleted, */
/* the pointers will be equal. */
CHECKL(CBSBlockBase(block) <= CBSBlockLimit(block));
/* If the block is in the middle of being deleted, the range might be empty. */
CHECKD_NOSIG(Range, &block->rangeStruct);
/* Can't check maxSize because it may be invalid at the time */
return TRUE;
}