[tor-bugs] #26196 [Core Tor/Tor]: Abort in test_bridges.c

Tor Bug Tracker & Wiki blackhole at torproject.org
Fri May 25 17:05:13 UTC 2018


#26196: Abort in test_bridges.c
--------------------------+------------------------------------
 Reporter:  gvanem        |          Owner:  (none)
     Type:  defect        |         Status:  new
 Priority:  Medium        |      Milestone:  Tor: 0.3.5.x-final
Component:  Core Tor/Tor  |        Version:  Tor: unspecified
 Severity:  Normal        |     Resolution:
 Keywords:  crash, tests  |  Actual Points:
Parent ID:                |         Points:
 Reviewer:                |        Sponsor:
--------------------------+------------------------------------

Comment (by catalyst):

 Replying to [comment:1 teor]:
 > To prevent bugs like this in future, we should make unit tests and
 fragile hardening set DEBUG_SMARTLIST.
 I agree with this approach. Also we should fix the test so it tests for
 zero length rather than checking for getting a null pointer from
 `smartlist_get(bridgelist, 0)` after the `clear_bridge_list()`. Unit tests
 generally shouldn't violate the invariants of code they're testing.

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/26196#comment:2>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list