Commit 55c38f88 authored by Nick Mathewson's avatar Nick Mathewson 🏃
Browse files

Remove string size limit on NEWDESC messages; solve bug 291.


svn:r6463
parent a915e5d1
......@@ -2852,8 +2852,12 @@ control_event_descriptors_changed(smartlist_t *routers)
tor_free(msg);
}
if (EVENT_IS_INTERESTING1(EVENT_NEW_DESC)) {
msg = smartlist_join_strings(identities, " ", 0, &len);
send_control1_event(EVENT_NEW_DESC, "650 NEWDESC %s\r\n", msg);
char *ids = smartlist_join_strings(identities, " ", 0, &len);
size_t len = strlen(ids)+32;
msg = tor_malloc(len);
tor_snprintf(msg, len, "650 NEWDESC %s\r\n", ids);
send_control1_event_string(EVENT_NEW_DESC, msg);
tor_free(ids);
tor_free(msg);
}
SMARTLIST_FOREACH(identities, char *, cp, tor_free(cp));
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment