Open jtbandes opened 1 month ago
The following schema triggers a segmentation fault:
enum Color : byte { Red = 1, Green, Blue } struct MyStruct { xyz:[Color:1]; }
$ flatc --version flatc version 24.3.25 $ flatc --ts --ts-no-import-ext --gen-object-api -o gen *.fbs zsh: segmentation fault flatc --ts --ts-no-import-ext --gen-object-api -o gen *.fbs
This seems to occur because 0 is not a valid value for Color. If you change Red = 1, to Red = 0, or just Red, then the crash no longer occurs.
0
Red = 1,
Red = 0,
Red,
If you remove the --gen-object-api the crash no longer occurs.
--gen-object-api
The following schema triggers a segmentation fault:
This seems to occur because
0
is not a valid value for Color. If you changeRed = 1,
toRed = 0,
or justRed,
then the crash no longer occurs.If you remove the
--gen-object-api
the crash no longer occurs.