#14013: base16_decode() API is inconsistent and error-prone -----------------------------------+------------------------------------ Reporter: nickm | Owner: nikkolasg Type: defect | Status: needs_revision Priority: High | Milestone: Tor: 0.2.9.x-final Component: Core Tor/Tor | Version: Severity: Normal | Resolution: Keywords: lorax, review-group-1 | Actual Points: Parent ID: | Points: small Reviewer: | Sponsor: SponsorS-can -----------------------------------+------------------------------------ Changes (by dgoulet):
* status: needs_review => needs_revision Comment: * `base16_decode()` comment needs to mention that we return the size now on success. * There is still this line looking for an error instead of `!=` to the expected size but all other fixes make that not equal change: {{{ + base16_decode(guard_id, DIGEST_LEN, inputs_tmp, HEX_DIGEST_LEN) < 0) { }}} * About this comment, can you tell us what's the returned value? It seems it should be `DIGEST256_LEN` indeed. {{{ + // XXX Should it not be always DIGEST256_LEN ? Running the tests with + // the condition ` != DIGEST256_LEN` fails. }}} -- Ticket URL: <https://trac.torproject.org/projects/tor/ticket/14013#comment:15> Tor Bug Tracker & Wiki <https://trac.torproject.org/> The Tor Project: anonymity online _______________________________________________ tor-bugs mailing list tor-bugs@lists.torproject.org https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-bugs