mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-11-24 04:13:28 +01:00
6e3e96d2ff
Our previous algorithm had a nonzero probability of picking no events to cancel, which is of course incorrect. The new code uses Vitter's good old reservoir sampling "algorithm R" from 1985. Fixes bug 26008; bugfix on 0.2.6.3-alpha.
8 lines
352 B
Plaintext
8 lines
352 B
Plaintext
o Minor bugfixes (test):
|
|
- When testing workqueue event-cancellation, make sure that we actually
|
|
cancel an event, and that cancel each event with equal probability.
|
|
(It was previously possible, though extremely unlikely, for our
|
|
event-canceling test not to cancel any events.) Fixes bug 26008;
|
|
bugfix on 0.2.6.3-alpha.
|
|
|