Adding assert and not using unitialized value even though it wouldn't have mattered.
This commit is contained in:
parent
82cfb5c2a6
commit
fe11c2901d
2 changed files with 5 additions and 1 deletions
|
@ -791,7 +791,10 @@ bool rai::node_config::deserialize_json (bool & upgraded_a, boost::property_tree
|
|||
boost::asio::ip::address address;
|
||||
uint16_t port;
|
||||
result |= rai::parse_address_port (work_peer, address, port);
|
||||
work_peers.push_back (std::make_pair (address, port));
|
||||
if (!result)
|
||||
{
|
||||
work_peers.push_back (std::make_pair (address, port));
|
||||
}
|
||||
}
|
||||
auto preconfigured_peers_l (tree_a.get_child ("preconfigured_peers"));
|
||||
preconfigured_peers.clear ();
|
||||
|
|
|
@ -671,6 +671,7 @@ std::unique_ptr <rai::block> rai::deserialize_block (rai::stream & stream_a, rai
|
|||
break;
|
||||
}
|
||||
default:
|
||||
assert (false);
|
||||
break;
|
||||
}
|
||||
return result;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue