aboutsummaryrefslogtreecommitdiff
path: root/src/feature/dirparse
diff options
context:
space:
mode:
authorcypherpunks <cypherpunks@torproject.org>2020-02-08 20:45:24 +0000
committercypherpunks <cypherpunks@torproject.org>2020-02-09 01:24:47 +0000
commitad1b378e87c4f2e000909abed41b80a1ec166113 (patch)
tree515b0e1875509a7dec38f702882043f1c69d9f47 /src/feature/dirparse
parentb3affc23ef263a978b89e783f55ad3e37c873b9a (diff)
downloadtor-ad1b378e87c4f2e000909abed41b80a1ec166113.tar.gz
tor-ad1b378e87c4f2e000909abed41b80a1ec166113.zip
dirparse: curlybraceify if statements
Diffstat (limited to 'src/feature/dirparse')
-rw-r--r--src/feature/dirparse/ns_parse.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/src/feature/dirparse/ns_parse.c b/src/feature/dirparse/ns_parse.c
index 2354ebf440..ce548b221e 100644
--- a/src/feature/dirparse/ns_parse.c
+++ b/src/feature/dirparse/ns_parse.c
@@ -1168,14 +1168,18 @@ networkstatus_parse_vote_from_string(const char *s, const char **eos_out,
}
}
- if ((tok = find_opt_by_keyword(tokens, K_RECOMMENDED_CLIENT_PROTOCOLS)))
+ if ((tok = find_opt_by_keyword(tokens, K_RECOMMENDED_CLIENT_PROTOCOLS))) {
ns->recommended_client_protocols = tor_strdup(tok->args[0]);
- if ((tok = find_opt_by_keyword(tokens, K_RECOMMENDED_RELAY_PROTOCOLS)))
+ }
+ if ((tok = find_opt_by_keyword(tokens, K_RECOMMENDED_RELAY_PROTOCOLS))) {
ns->recommended_relay_protocols = tor_strdup(tok->args[0]);
- if ((tok = find_opt_by_keyword(tokens, K_REQUIRED_CLIENT_PROTOCOLS)))
+ }
+ if ((tok = find_opt_by_keyword(tokens, K_REQUIRED_CLIENT_PROTOCOLS))) {
ns->required_client_protocols = tor_strdup(tok->args[0]);
- if ((tok = find_opt_by_keyword(tokens, K_REQUIRED_RELAY_PROTOCOLS)))
+ }
+ if ((tok = find_opt_by_keyword(tokens, K_REQUIRED_RELAY_PROTOCOLS))) {
ns->required_relay_protocols = tor_strdup(tok->args[0]);
+ }
tok = find_by_keyword(tokens, K_VALID_AFTER);
if (parse_iso_time(tok->args[0], &ns->valid_after))