File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -50,6 +50,7 @@ lru-slab = { workspace = true }
5050qlog = { workspace = true , optional = true }
5151rustc-hash = { workspace = true }
5252rand = { workspace = true }
53+ rand_pcg = " 0.10"
5354ring = { workspace = true , optional = true }
5455rustls = { workspace = true , optional = true }
5556rustls-platform-verifier = { workspace = true , optional = true }
@@ -69,7 +70,6 @@ web-time = { workspace = true }
6970[dev-dependencies ]
7071assert_matches = { workspace = true }
7172hex-literal = { workspace = true }
72- rand_pcg = " 0.10"
7373rcgen = { workspace = true }
7474tracing-subscriber = { workspace = true }
7575lazy_static = " 1"
Original file line number Diff line number Diff line change @@ -2,8 +2,8 @@ use std::any::Any;
22use std:: fmt:: Debug ;
33use std:: sync:: Arc ;
44
5- use rand:: rngs :: { StdRng , SysRng } ;
6- use rand :: { Rng , RngExt , SeedableRng } ;
5+ use rand:: { RngExt , SeedableRng } ;
6+ use rand_pcg :: Pcg32 ;
77
88use crate :: congestion:: ControllerMetrics ;
99use crate :: congestion:: bbr:: bw_estimation:: BandwidthEstimation ;
@@ -57,7 +57,7 @@ pub struct Bbr {
5757 bw_at_last_round : u64 ,
5858 round_wo_bw_gain : u64 ,
5959 ack_aggregation : AckAggregationState ,
60- random_number_generator : StdRng ,
60+ random_number_generator : Pcg32 ,
6161}
6262
6363impl Bbr {
@@ -98,7 +98,7 @@ impl Bbr {
9898 bw_at_last_round : 0 ,
9999 round_wo_bw_gain : 0 ,
100100 ack_aggregation : AckAggregationState :: default ( ) ,
101- random_number_generator : StdRng :: try_from_rng ( & mut SysRng ) . unwrap ( ) ,
101+ random_number_generator : Pcg32 :: from_rng ( & mut rand :: rng ( ) ) ,
102102 }
103103 }
104104
You can’t perform that action at this time.
0 commit comments