diff options
| author | Carl Hetherington <cth@carlh.net> | 2015-05-20 16:29:15 +0100 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2015-05-20 16:29:15 +0100 |
| commit | ada329f77032590bae1e18d05a87f94c82e14a55 (patch) | |
| tree | 147dca4dcbf5de5dfd51749cb2f342b278e1b578 /src/lib/server_finder.cc | |
| parent | f91d0e7734dc2c42ed9c9b953c6a57e530ea43f8 (diff) | |
Don't put servers on the list if they report the wrong link version.
Diffstat (limited to 'src/lib/server_finder.cc')
| -rw-r--r-- | src/lib/server_finder.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lib/server_finder.cc b/src/lib/server_finder.cc index 979046dab..f347132e4 100644 --- a/src/lib/server_finder.cc +++ b/src/lib/server_finder.cc @@ -167,7 +167,7 @@ ServerFinder::handle_accept (boost::system::error_code ec, shared_ptr<Socket> so xml->read_string (s); string const ip = socket->socket().remote_endpoint().address().to_string (); - if (!server_found (ip)) { + if (!server_found (ip) && xml->optional_number_child<int>("Version").get_value_or (0) == SERVER_LINK_VERSION) { ServerDescription sd (ip, xml->number_child<int> ("Threads")); { boost::mutex::scoped_lock lm (_mutex); |
