Skip to content
This repository has been archived by the owner on Feb 1, 2024. It is now read-only.

Fix clippy::single_range_in_vec_init lint #88

Merged
merged 1 commit into from
Dec 5, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/consensus/zmq_driver.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ const MAX_RETRY_DELAY: Duration = Duration::from_secs(3);
fn generate_correlation_id() -> String {
const LENGTH: usize = 16;
let mut rng = rand::thread_rng();
[0..LENGTH]
[0; LENGTH]
.iter()
.map(|_| rng.sample(Alphanumeric))
.map(char::from)
Expand Down
2 changes: 1 addition & 1 deletion src/consensus/zmq_service.rs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ use std::time::Duration;
fn generate_correlation_id() -> String {
const LENGTH: usize = 16;
let mut rng = rand::thread_rng();
[0..LENGTH]
[0; LENGTH]
.iter()
.map(|_| rng.sample(Alphanumeric))
.map(char::from)
Expand Down
2 changes: 1 addition & 1 deletion src/processor/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ use self::zmq_context::ZmqTransactionContext;
fn generate_correlation_id() -> String {
const LENGTH: usize = 16;
let mut rng = rand::thread_rng();
[0..LENGTH]
[0; LENGTH]
.iter()
.map(|_| rng.sample(Alphanumeric))
.map(char::from)
Expand Down
Loading