Skip to content

Commit

Permalink
Merge pull request EOSIO#90 from boscore/develop
Browse files Browse the repository at this point in the history
 sort view change and producer vector before intersection.
  • Loading branch information
Thaipanda authored Apr 30, 2019
2 parents 96b3e81 + 6c65226 commit 59c5bf6
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions libraries/chain/pbft_database.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -786,6 +786,9 @@ namespace eosio {
}

vector<public_key_type> intersection;

std::sort(lib_producers.begin(),lib_producers.end());
std::sort(view_change_producers.begin(),view_change_producers.end());
std::set_intersection(lib_producers.begin(),lib_producers.end(),
view_change_producers.begin(),view_change_producers.end(),
back_inserter(intersection));
Expand Down

0 comments on commit 59c5bf6

Please sign in to comment.