#245 Add try-catch block for update_account_histories
This commit is contained in:
parent
43fbe98240
commit
910362baf8
1 changed files with 114 additions and 99 deletions
|
|
@ -79,6 +79,8 @@ account_history_plugin_impl::~account_history_plugin_impl()
|
|||
|
||||
void account_history_plugin_impl::update_account_histories( const signed_block& b )
|
||||
{
|
||||
try \
|
||||
{
|
||||
graphene::chain::database& db = database();
|
||||
vector<optional< operation_history_object > >& hist = db.get_applied_operations();
|
||||
bool is_first = true;
|
||||
|
|
@ -197,6 +199,19 @@ void account_history_plugin_impl::update_account_histories( const signed_block&
|
|||
if (_partial_operations && ! oho.valid())
|
||||
skip_oho_id();
|
||||
}
|
||||
}
|
||||
catch( const boost::exception& e )
|
||||
{
|
||||
elog( "Caught account_history_plugin::update_account_histories(...) boost::exception: ${e}", ("e", boost::diagnostic_information(e) ) );
|
||||
}
|
||||
catch( const std::exception& e )
|
||||
{
|
||||
elog( "Caught account_history_plugin::update_account_histories(...) std::exception: ${e}", ("e", e.what() ) );
|
||||
}
|
||||
catch( ... )
|
||||
{
|
||||
wlog( "Caught unexpected exception in account_history_plugin::update_account_histories(...)" );
|
||||
}
|
||||
}
|
||||
|
||||
void account_history_plugin_impl::add_account_history( const account_id_type account_id, const operation_history_id_type op_id )
|
||||
|
|
|
|||
Loading…
Reference in a new issue