Removing keepalive callback passed in through start_tcp as unnecessary.

This commit is contained in:
clemahieu 2021-09-11 21:28:58 +01:00
commit 6552a82c7e
No known key found for this signature in database
GPG key ID: 43708520C8DFB938

View file

@ -45,12 +45,7 @@ void nano::node::keepalive (std::string const & address_a, uint16_t port_a)
auto channel (node_l->network.find_channel (endpoint));
if (!channel)
{
node_l->network.tcp_channels.start_tcp (endpoint, [node_w] (std::shared_ptr<nano::transport::channel> const & channel_a) {
if (auto node_l = node_w.lock ())
{
node_l->network.send_keepalive (channel_a);
}
});
node_l->network.tcp_channels.start_tcp (endpoint);
}
else
{