realm-core: Assertion failed: Array::get_context_flag_from_header...
Originally reported on Helpscout:
../realm/index_string.hpp:359: [realm-core-2.1.4] Assertion failed: Array::get_context_flag_from_header(alloc.translate(ref)) with (ref, size_t(alloc.translate(ref))) = [6554408, 4411638568]
0 Realm 0x00000001024828ec _ZN5realm4utilL18terminate_internalERNSt3__118basic_stringstreamIcNS1_11char_traitsIcEENS1_9allocatorIcEEEE + 44
1 Realm 0x0000000102482d5c _ZN5realm4util19terminate_with_infoEPKcS2_lS2_OSt16initializer_listINS0_9PrintableEE + 432
2 Realm 0x0000000102508edc _ZNK5realm16ColumnBaseSimple9get_allocEv + 0
3 Realm 0x000000010251d3bc _ZN5realm12StringColumn39set_search_index_allow_duplicate_valuesEb + 0
4 Realm 0x00000001025a5bf4 _ZN5realm5Table24refresh_column_accessorsEm + 844
5 Realm 0x000000010252cbe0 _ZN5realm5Group21create_table_accessorEm + 280
6 Realm 0x000000010252ca3c _ZN5realm5Group12do_get_tableEmPFbRKNS_4SpecEE + 220
7 Realm 0x00000001025a5ae8 _ZN5realm5Table24refresh_column_accessorsEm + 576
8 Realm 0x000000010252cbe0 _ZN5realm5Group21create_table_accessorEm + 280
9 Realm 0x000000010252ca3c _ZN5realm5Group12do_get_tableEmPFbRKNS_4SpecEE + 220
10 Realm 0x0000000102357954 _ZN5realm12ObjectSchemaC2ERKNS_5GroupENS_10StringDataEm + 148
11 Realm 0x000000010235c710 _ZN5realm11ObjectStore17schema_from_groupERKNS_5GroupE + 284
12 Realm 0x0000000102410388 _ZN5realm5Realm4initENSt3__110shared_ptrINS_5_impl16RealmCoordinatorEEE + 128
13 Realm 0x00000001023638e0 _ZN5realm5_impl16RealmCoordinator9get_realmENS_5Realm6ConfigE + 560
14 Realm 0x0000000102411744 _ZN5realm5Realm16get_shared_realmENS0_6ConfigE + 244
15 Realm 0x00000001023f329c +[RLMRealm realmWithConfiguration:error:] + 568
16 RealmSwift 0x00000001028a821c _TFC10RealmSwift5RealmCfzT_S0_ + 120
About this issue
- Original URL
- State: closed
- Created 8 years ago
- Comments: 19 (14 by maintainers)
We have now found out that the root problem is a double free of some block. Now we just need to find it.
Next finding: It is probably not a double free in classical terms. It turns out that the 2 identical entries in the free list are from 2 subsequent versions. This probably means that a ref is freed in one transaction, but not replaced in the db tree. In the next transaction it is then freed again. This could suggest a missing update_parent.