bug #245 exception seen in witness logs
This commit is contained in:
parent
10799a2148
commit
78fbf7c3cd
2 changed files with 136 additions and 112 deletions
|
|
@ -23,6 +23,7 @@
|
|||
*/
|
||||
#pragma once
|
||||
|
||||
#include <boost/exception/diagnostic_information.hpp>
|
||||
#include <fc/exception/exception.hpp>
|
||||
#include <graphene/chain/protocol/protocol.hpp>
|
||||
|
||||
|
|
@ -75,6 +76,14 @@
|
|||
elog( "Caught plugin exception: ${e}", ("e", e.to_detail_string() ) ); \
|
||||
throw; \
|
||||
} \
|
||||
catch( const boost::exception& e ) \
|
||||
{ \
|
||||
elog( "Caught plugin boost::exception: ${e}", ("e", boost::diagnostic_information(e) ) ); \
|
||||
} \
|
||||
catch( const std::exception& e ) \
|
||||
{ \
|
||||
elog( "Caught plugin std::exception: ${e}", ("e", e.what() ) ); \
|
||||
} \
|
||||
catch( ... ) \
|
||||
{ \
|
||||
wlog( "Caught unexpected exception in plugin" ); \
|
||||
|
|
|
|||
|
|
@ -78,6 +78,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();
|
||||
|
|
@ -198,6 +200,19 @@ void account_history_plugin_impl::update_account_histories( const signed_block&
|
|||
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