diff options
author | Roger Dingledine <arma@torproject.org> | 2006-02-15 03:01:53 +0000 |
---|---|---|
committer | Roger Dingledine <arma@torproject.org> | 2006-02-15 03:01:53 +0000 |
commit | f6d80d60e01b3e2e80901234b9e9c38ee1c4fe86 (patch) | |
tree | bcbef76abf8a8f73f8afed877c34a359808fd75a /src/or | |
parent | 3a48b3e1868e843c17ed1031006ac9b52d7d63ac (diff) | |
download | tor-f6d80d60e01b3e2e80901234b9e9c38ee1c4fe86.tar.gz tor-f6d80d60e01b3e2e80901234b9e9c38ee1c4fe86.zip |
don't warn when we get a server descriptor from the controller
but it's too old. that's not something tor should fix.
svn:r6019
Diffstat (limited to 'src/or')
-rw-r--r-- | src/or/routerlist.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/or/routerlist.c b/src/or/routerlist.c index 2b8922a093..d642b02b17 100644 --- a/src/or/routerlist.c +++ b/src/or/routerlist.c @@ -1820,6 +1820,7 @@ int router_load_single_router(const char *s, const char **msg) { routerinfo_t *ri; + int r; smartlist_t *lst; tor_assert(msg); *msg = NULL; @@ -1840,10 +1841,11 @@ router_load_single_router(const char *s, const char **msg) smartlist_add(lst, ri); routers_update_status_from_networkstatus(lst, 0); - if (router_add_to_routerlist(ri, msg, 0, 0)<0) { - log_warn(LD_DIR, "Couldn't add router to list: %s Dropping.", - *msg?*msg:"(No message)."); + if ((r=router_add_to_routerlist(ri, msg, 0, 0))<0) { /* we've already assigned to *msg now, and ri is already freed */ + tor_assert(*msg); + if (r < -1) + log_warn(LD_DIR, "Couldn't add router to list: %s Dropping.", *msg); smartlist_free(lst); return 0; } else { |