[SON-339] - SON Schedule crash (#334)

Co-authored-by: satyakoneru <15652887+satyakoneru@users.noreply.github.com>
This commit is contained in:
sierra19XX 2020-04-04 14:36:28 +11:00 committed by GitHub
parent e1a487c87b
commit 1542a9a8e4
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -730,6 +730,13 @@ void database::update_active_sons()
return swi.son_id;
});
_sso.scheduler.update(active_sons);
// similar to witness, produce schedule for sons
if(cur_active_sons.size() == 0 && new_active_sons.size() > 0)
{
witness_scheduler_rng rng(_sso.rng_seed.begin(), GRAPHENE_NEAR_SCHEDULE_CTR_IV);
for( size_t i=0; i<new_active_sons.size(); ++i )
_sso.scheduler.produce_schedule(rng);
}
});
} FC_CAPTURE_AND_RETHROW() }