Skip to content

Commit 6f19165

Browse files
authored
Merge pull request #568 from stjepang/fix-random
Fix rng use in Stream::merge
2 parents 2ca03ca + 5fba3a0 commit 6f19165

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/stream/stream/merge.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ where
4444

4545
fn poll_next(self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Option<Self::Item>> {
4646
let this = self.project();
47-
if utils::random(1) == 1 {
47+
if utils::random(2) == 0 {
4848
poll_next_in_order(this.left, this.right, cx)
4949
} else {
5050
poll_next_in_order(this.right, this.left, cx)

0 commit comments

Comments
 (0)