message: remove limit on deserializing forkdb.dat
diff: @@ -61,10 +61,10 @@ namespace eosio { namespace chain {
  fc::read_file_contents( fork_db_dat, content );
  fc::datastream<const char*> ds( content.data(), content.size() );
  - vector<block_state> states;
  - fc::raw::unpack( ds, states );
  -
  - for( auto& s : states ) {
  + unsigned_int size; fc::raw::unpack( ds, size );
  + for( uint32_t i = 0, n = size.value; i < n; ++i ) {
  + block_state s;
  + fc::raw::unpack( ds, s );
  set( std::make_shared<block_state>( move( s ) ) );
  }
  block_id_type head_id;
  @@ -78,20 +78,19 @@ namespace eosio { namespace chain {
  if( my->index.size() == 0 ) return;
  fc::datastream<size_t> ps;
  - vector<block_state> states;
  - states.reserve( my->index.size() );
  - for( const auto& s : my->index ) {
  - states.push_back( *s );
  - }
  auto fork_db_dat = my->datadir / "forkdb.dat";
  std::ofstream out( fork_db_dat.generic_string().c_str(), std::ios::out | std::ios::binary | std::ofstream::trunc );
  - fc::raw::pack( out, states );
  + uint32_t num_blocks_in_fork_db = my->index.size();
  + fc::raw::pack( out, unsigned_int{num_blocks_in_fork_db} );
  + for( const auto& s : my->index ) {
  + fc::raw::pack( out, *s );
  + }
  if( my->head )
  fc::raw::pack( out, my->head->id );
  else
  fc::raw::pack( out, block_id_type() );
  - idump((states.size()));
  + idump((num_blocks_in_fork_db));
  /// we don't normally indicate the head block as irreversible
  