diff options
author | Nick Mathewson <nickm@torproject.org> | 2010-09-14 13:50:28 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2010-09-14 13:50:28 -0400 |
commit | a445daf0cf7e7828aefacae1a11df5e76efacafa (patch) | |
tree | 3dd68f28f7be229e471d9856b1a5639ecbe811f7 /src/or/routerlist.c | |
parent | 424ca963ad7b08822b82491fbeba05438ddf5da2 (diff) | |
parent | 33ae3f4b5c5bffd8ab6fae34f90b0bd5b0fa0ce5 (diff) | |
download | tor-a445daf0cf7e7828aefacae1a11df5e76efacafa.tar.gz tor-a445daf0cf7e7828aefacae1a11df5e76efacafa.zip |
Merge remote branch 'sebastian/bug1776_v3'
Diffstat (limited to 'src/or/routerlist.c')
-rw-r--r-- | src/or/routerlist.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/or/routerlist.c b/src/or/routerlist.c index 5bdc973b2c..ca16456a8c 100644 --- a/src/or/routerlist.c +++ b/src/or/routerlist.c @@ -3176,8 +3176,10 @@ router_add_to_routerlist(routerinfo_t *router, const char **msg, /* If we have this descriptor already and the new descriptor is a bridge * descriptor, replace it. If we had a bridge descriptor before and the * new one is not a bridge descriptor, don't replace it. */ - if (old_router && (!routerinfo_is_a_configured_bridge(router) || - routerinfo_is_a_configured_bridge(old_router))) { + tor_assert(old_router); + if (! (routerinfo_is_a_configured_bridge(router) && + (router->purpose == ROUTER_PURPOSE_BRIDGE || + old_router->purpose != ROUTER_PURPOSE_BRIDGE))) { log_info(LD_DIR, "Dropping descriptor that we already have for router '%s'", router->nickname); |