mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-06 19:41:15 +01:00
if there's more than one match for router-get-my-nickname,
try to pick one that's running. svn:r6313
This commit is contained in:
+2
-1
@@ -944,7 +944,8 @@ router_get_by_nickname(const char *nickname, int warn_if_unnamed)
|
||||
return router;
|
||||
else {
|
||||
++n_matches;
|
||||
best_match = router;
|
||||
if (n_matches <= 1 || router->is_running)
|
||||
best_match = router;
|
||||
}
|
||||
} else if (maybedigest &&
|
||||
!memcmp(digest, router->cache_info.identity_digest, DIGEST_LEN)
|
||||
|
||||
Reference in New Issue
Block a user