mirror of
https://github.com/JakeHillion/object-introspection.git
synced 2024-09-19 11:09:05 +01:00
7de35863f5
Thrift isset was failing with a SEGV if the struct contained padding. This is because we indexed the `isset_indexes` data structure using our field index rather than the index of the field in Thrift. This then gave a rubbish index for any exceeding which happens if we have added padding in the middle of the struct, and this index was looked up in the bitset which can cause a SEGV. Track a new index `thriftFieldIdx` which is only incremented if we've looked up a Thrift index. Namespaced the generated Thrift structs while I was there. This isn't necessary anymore but cleans things up. Test plan: - Added a test case with lots of padding. These don't run in the CI but it passes locally. - `FILTER='OilIntegration.*' make test` - no failures - `FILTER='OidIntegration.*' make test` - no new failures |
||
---|---|---|
.. | ||
integration | ||
ci.oid.toml | ||
CMakeLists.txt | ||
integration_entry_doStuff_arg0.oid | ||
integration_entry_doStuff_this.oid | ||
integration_entry_inc_arg0.oid | ||
integration_mttest.cpp | ||
integration_return_incN_arg0.oid | ||
integration_sleepy.cpp | ||
integration.py | ||
main.cpp | ||
mocks.h | ||
mttest.h | ||
test_add_children.cpp | ||
test_add_padding.cpp | ||
test_alignment_calc.cpp | ||
test_codegen.cpp | ||
test_compiler.cpp | ||
test_container_info.cpp | ||
test_drgn_parser.cpp | ||
test_drgn_parser.h | ||
test_enforce_compatibility.cpp | ||
test_flattener.cpp | ||
test_identify_containers.cpp | ||
test_key_capture.cpp | ||
test_name_gen.cpp | ||
test_node_tracker.cpp | ||
test_parser.cpp | ||
test_prune.cpp | ||
test_remove_members.cpp | ||
test_remove_top_level_pointer.cpp | ||
test_topo_sorter.cpp | ||
test_type_identifier.cpp | ||
type_graph_utils.cpp | ||
type_graph_utils.h | ||
TypeGraphParser.cpp | ||
TypeGraphParser.h |