[tor-bugs] #4283 [Tor Client]: crypto_pk_cmp_keys does not document its error behaviour
Tor Bug Tracker & Wiki
torproject-admin at torproject.org
Thu Sep 13 19:05:43 UTC 2012
#4283: crypto_pk_cmp_keys does not document its error behaviour
------------------------+---------------------------------------------------
Reporter: rransom | Owner:
Type: defect | Status: new
Priority: normal | Milestone: Tor: 0.2.4.x-final
Component: Tor Client | Version:
Keywords: | Parent:
Points: | Actualpoints:
------------------------+---------------------------------------------------
Comment(by rransom):
From `router_differences_are_cosmetic` in `src/or/routerlist.c`:
{{{
crypto_pk_cmp_keys(r1->onion_pkey, r2->onion_pkey) ||
crypto_pk_cmp_keys(r1->identity_pkey, r2->identity_pkey) ||
}}}
Someday, this will need a comparison function which handles NULL keys
properly (i.e. as equal to each other, and distinct from non-NULL keys).
This call site can use an (in)equality comparison rather than an order
comparison.
--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/4283#comment:5>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online
More information about the tor-bugs
mailing list