aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/or/router.c1
-rw-r--r--src/or/routerlist.c6
2 files changed, 7 insertions, 0 deletions
diff --git a/src/or/router.c b/src/or/router.c
index 0e36f98d5..796a49d8f 100644
--- a/src/or/router.c
+++ b/src/or/router.c
@@ -1031,6 +1031,7 @@ router_rebuild_descriptor(int force)
/* Now generate the extrainfo. */
ei = tor_malloc_zero(sizeof(extrainfo_t));
+ ei->cache_info.is_extrainfo = 1;
strlcpy(ei->nickname, get_options()->Nickname, sizeof(ei->nickname));
ei->cache_info.published_on = ri->cache_info.published_on;
memcpy(ei->cache_info.identity_digest, ri->cache_info.identity_digest,
diff --git a/src/or/routerlist.c b/src/or/routerlist.c
index ee7b7023a..61c65dd23 100644
--- a/src/or/routerlist.c
+++ b/src/or/routerlist.c
@@ -1798,6 +1798,12 @@ extrainfo_insert(routerlist_t *rl, extrainfo_t *ei)
extrainfo_t *ei_tmp;
routerlist_check_bug_417();
+ {
+ /* XXXX020 remove this code once bug 417/404 is fixed. */
+ extrainfo_t *ei_generated = router_get_my_extrainfo();
+ tor_assert(ei_generated != ei);
+ }
+
if (!ri) {
/* This router is unknown; we can't even verify the signature. Give up.*/
goto done;