mirror of
https://github.com/google/flatbuffers.git
synced 2026-06-12 16:00:59 +00:00
Handle root offset and root table vtable invalidation (#7177)
* Handle invalid root offset * Handle vtable offset invalidation * Added script generator. Add more cases through vtable ref table size * review responses * vtable offset validation * Moved padding insertion to the end. Tests invalid field lenghts * table offsets validated. Added type after field * validate string length * add todo * invalid vector length * invalid structs * general cleanup * reworded invalid offsets * example for vector of structs * invalid vector of tables * invalid vector of strings * invalid vector of scalars * vector of unions * validate union type value * invalid vector union type values
This commit is contained in:
@@ -37,6 +37,7 @@ table Type {
|
||||
index:int = -1; // If base_type == Object, index into "objects" below.
|
||||
// If base_type == Union, UnionType, or integral derived
|
||||
// from an enum, index into "enums" below.
|
||||
// If base_type == Vector && element == Union or UnionType.
|
||||
fixed_length:uint16 = 0; // Only if base_type == Array.
|
||||
/// The size (octets) of the `base_type` field.
|
||||
base_size:uint = 4; // 4 Is a common size due to offsets being that size.
|
||||
|
||||
Reference in New Issue
Block a user