Fixes verifier not catching odd vtable sizes.
Bug: 28762769 Change-Id: Iec370482f67c4585e97dd5175c1a4258ddba47fe Tested: on Linux.
This commit is contained in:
parent
7cce55d8f0
commit
69eef0a0ec
|
@ -1383,6 +1383,7 @@ class Table {
|
|||
// Check the vtable size field, then check vtable fits in its entirety.
|
||||
return verifier.VerifyComplexity() &&
|
||||
verifier.Verify<voffset_t>(vtable) &&
|
||||
(ReadScalar<voffset_t>(vtable) & (sizeof(voffset_t) - 1)) == 0 &&
|
||||
verifier.Verify(vtable, ReadScalar<voffset_t>(vtable));
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue