diff options
author | teor <teor@torproject.org> | 2019-06-06 09:57:31 +1000 |
---|---|---|
committer | teor <teor@torproject.org> | 2019-06-06 09:57:31 +1000 |
commit | c7fc53c2e77f9931bc607a414e289dcebbcee516 (patch) | |
tree | 4834c36e4ed0714e2b890863502554fe52db1897 /src | |
parent | 3c2b2f072f996ba958ed5b6e07d3bac02291fc4a (diff) | |
parent | fb3f461406d9d22da3ce0b602409c6610b8bb4f7 (diff) | |
download | tor-c7fc53c2e77f9931bc607a414e289dcebbcee516.tar.gz tor-c7fc53c2e77f9931bc607a414e289dcebbcee516.zip |
Merge branch 'bug30781_040' into bug30781_master
Diffstat (limited to 'src')
-rw-r--r-- | src/feature/dirparse/routerparse.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/feature/dirparse/routerparse.c b/src/feature/dirparse/routerparse.c index ff7e15f1f2..f78c46f186 100644 --- a/src/feature/dirparse/routerparse.c +++ b/src/feature/dirparse/routerparse.c @@ -556,6 +556,9 @@ router_parse_entry_from_string(const char *s, const char *end, if ((tok = find_opt_by_keyword(tokens, A_PURPOSE))) { tor_assert(tok->n_args); router->purpose = router_purpose_from_string(tok->args[0]); + if (router->purpose == ROUTER_PURPOSE_UNKNOWN) { + goto err; + } } else { router->purpose = ROUTER_PURPOSE_GENERAL; } |