diff options
author | Nick Mathewson <nickm@torproject.org> | 2018-08-28 15:44:06 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2018-08-28 15:44:06 -0400 |
commit | 2bc4c55d7d17ba9d4dcfacd3f2b118e7144a146d (patch) | |
tree | e13c924935116bf25ad5fb5f259d2aca51140882 /src/test | |
parent | 82d758afa80724f4b8322e002d351c8e7923062a (diff) | |
parent | f282375fb7d9c527e4bff19dc1e8c6dc7627d137 (diff) | |
download | tor-2bc4c55d7d17ba9d4dcfacd3f2b118e7144a146d.tar.gz tor-2bc4c55d7d17ba9d4dcfacd3f2b118e7144a146d.zip |
Merge remote-tracking branch 'tor-github/pr/245'
Diffstat (limited to 'src/test')
-rw-r--r-- | src/test/test_options.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/src/test/test_options.c b/src/test/test_options.c index 801b5895ff..71d2193d1f 100644 --- a/src/test/test_options.c +++ b/src/test/test_options.c @@ -1656,6 +1656,18 @@ test_options_validate__reachable_addresses(void *ignored) tt_str_op(tdata->opt->ReachableAddresses->value, OP_EQ, "*:82"); tor_free(msg); + free_options_test_data(tdata); + mock_clean_saved_logs(); + tdata = get_options_test_data("FascistFirewall 1\n" + "ReachableAddresses *:82\n" + "MaxClientCircuitsPending 1\n" + "ConnLimit 1\n"); + + ret = options_validate(tdata->old_opt, tdata->opt, tdata->def_opt, 0, &msg); + tt_int_op(ret, OP_EQ, -1); + tt_ptr_op(tdata->opt->ReachableAddresses->next, OP_EQ, NULL); + tor_free(msg); + #define SERVERS_REACHABLE_MSG "Servers must be able to freely connect to" \ " the rest of the Internet, so they must not set Reachable*Addresses or" \ " FascistFirewall or FirewallPorts or ClientUseIPv4 0." |