void wallet_db::set_master_key( const extended_private_key& extended_key, const fc::sha512& new_password ) { master_key key; key.encrypt_key(new_password,extended_key); auto key_record = wallet_master_key_record( key, -1 ); store_record( key_record, true ); }
void wallet_db::set_master_key( const extended_private_key& extended_key, const fc::sha512& new_password ) { try { master_key key; key.encrypt_key( new_password, extended_key ); auto key_record = wallet_master_key_record( key, -1 ); store_and_reload_record( key_record, true ); } FC_CAPTURE_AND_RETHROW() }