the "last seen time" will never be updated, so the server will
be discarded.
It seems that we should always ping servers (so that set_seen gets
called on receipt of the response), no matter whether
"auto-discovered" or configured, so that the "discard" code doesn't
kick in.
Otherwise we remove and re-add our configured servers every
10 seconds, which is inefficient and which possibly triggers
other bugs.
/* Query our `definite' servers (if there are any) */
BOOST_FOREACH (string const& i, Config::instance()->servers()) {
- if (server_found(i)) {
- /* Don't bother asking a server that we already know about */
- continue;
- }
try {
boost::asio::ip::udp::resolver resolver (io_service);
boost::asio::ip::udp::resolver::query query (i, raw_convert<string> (HELLO_PORT));