mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-06 19:41:15 +01:00
Stop dying when we get a directory from tor26; workaround for change in networkstatus format
svn:r4933
This commit is contained in:
@@ -133,6 +133,8 @@ static struct {
|
||||
{ "dir-signing-key", K_DIR_SIGNING_KEY, ARGS, OBJ_OK, DIR|NETSTATUS},
|
||||
{ "family", K_FAMILY, ARGS, NO_OBJ, RTR },
|
||||
{ "fingerprint", K_FINGERPRINT, ARGS, NO_OBJ, ANY },
|
||||
/* XXXX NM obsolete; remove once tor26 upgrades. */
|
||||
{ "dir-fingerprint", K_FINGERPRINT, ARGS, NO_OBJ, NETSTATUS },
|
||||
{ "hibernating", K_HIBERNATING, ARGS, NO_OBJ, RTR },
|
||||
{ "read-history", K_READ_HISTORY, ARGS, NO_OBJ, RTR },
|
||||
{ "write-history", K_WRITE_HISTORY, ARGS, NO_OBJ, RTR },
|
||||
@@ -1412,7 +1414,8 @@ networkstatus_parse_from_string(const char *s)
|
||||
|
||||
goto done;
|
||||
err:
|
||||
networkstatus_free(ns);
|
||||
if (ns)
|
||||
networkstatus_free(ns);
|
||||
ns = NULL;
|
||||
done:
|
||||
SMARTLIST_FOREACH(tokens, directory_token_t *, t, token_free(t));
|
||||
|
||||
Reference in New Issue
Block a user