diff --git a/include/flatbuffers/flatbuffers.h b/include/flatbuffers/flatbuffers.h index c78583cad..0fa31250f 100644 --- a/include/flatbuffers/flatbuffers.h +++ b/include/flatbuffers/flatbuffers.h @@ -1383,6 +1383,7 @@ class Table { // Check the vtable size field, then check vtable fits in its entirety. return verifier.VerifyComplexity() && verifier.Verify(vtable) && + (ReadScalar(vtable) & (sizeof(voffset_t) - 1)) == 0 && verifier.Verify(vtable, ReadScalar(vtable)); }