Replace flat_index with generic_index for bitasset_object
- this enabled me to produce blocks and fixed corruption
This commit is contained in:
parent
be9138e227
commit
1c97c13eed
2 changed files with 5 additions and 3 deletions
|
|
@ -1409,8 +1409,9 @@ void database::perform_chain_maintenance(const signed_block& next_block, const g
|
|||
});
|
||||
|
||||
// Reset all BitAsset force settlement volumes to zero
|
||||
for( const asset_bitasset_data_object* d : get_index_type<asset_bitasset_data_index>() )
|
||||
modify(*d, [](asset_bitasset_data_object& d) { d.force_settled_volume = 0; });
|
||||
//for( const asset_bitasset_data_object* d : get_index_type<asset_bitasset_data_index>() )
|
||||
for( const auto& d : get_index_type<asset_bitasset_data_index>().indices() )
|
||||
modify( d, [](asset_bitasset_data_object& o) { o.force_settled_volume = 0; });
|
||||
|
||||
// process_budget needs to run at the bottom because
|
||||
// it needs to know the next_maintenance_time
|
||||
|
|
|
|||
|
|
@ -235,7 +235,8 @@ namespace graphene { namespace chain {
|
|||
>
|
||||
>
|
||||
> asset_bitasset_data_object_multi_index_type;
|
||||
typedef flat_index<asset_bitasset_data_object> asset_bitasset_data_index;
|
||||
//typedef flat_index<asset_bitasset_data_object> asset_bitasset_data_index;
|
||||
typedef generic_index<asset_bitasset_data_object, asset_bitasset_data_object_multi_index_type> asset_bitasset_data_index;
|
||||
|
||||
struct by_symbol;
|
||||
struct by_type;
|
||||
|
|
|
|||
Loading…
Reference in a new issue