diff options
author | Nick Mathewson <nickm@torproject.org> | 2012-10-22 17:34:05 -0400 |
---|---|---|
committer | Nick Mathewson <nickm@torproject.org> | 2012-10-23 13:49:48 -0400 |
commit | 85659d3964669f9f419123c648e517f4ba539462 (patch) | |
tree | cf95df6542f0219c67d9ebe2963a3ef46fb687ca /src/or/policies.h | |
parent | 4c8b58f9005b7a187878273b8ff0f8ec23e86326 (diff) | |
download | tor-85659d3964669f9f419123c648e517f4ba539462.tar.gz tor-85659d3964669f9f419123c648e517f4ba539462.zip |
Fix parse_short_policy (bug 7192.)
Our implementation of parse_short_policy was screwed up: it would
ignore the last character of every short policy. Obviously, that's
broken.
This patch fixes the busted behavior, and adds a bunch of unit tests
to make sure the rest of that function is okay.
Fixes bug 7192; fix on 0.2.3.1-alpha.
Diffstat (limited to 'src/or/policies.h')
-rw-r--r-- | src/or/policies.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/or/policies.h b/src/or/policies.h index b385d8e490..f00d8299b8 100644 --- a/src/or/policies.h +++ b/src/or/policies.h @@ -61,7 +61,7 @@ void policies_free_all(void); char *policy_summarize(smartlist_t *policy); short_policy_t *parse_short_policy(const char *summary); -const char *write_short_policy(const short_policy_t *policy); +char *write_short_policy(const short_policy_t *policy); void short_policy_free(short_policy_t *policy); int short_policy_is_reject_star(const short_policy_t *policy); addr_policy_result_t compare_tor_addr_to_short_policy( |