clippy::needless_pass_by_ref_mut

This commit is contained in:
Cyril Plisko 2023-08-08 11:10:10 +03:00
parent e06d2ae1a8
commit 6b72d18a7b

View file

@ -160,7 +160,7 @@ fn make_lengths<ByteBuf: AsRef<[u8]>>(
Lengths::new(total_length, torrent.piece_length, None)
}
fn ensure_file_length(file: &mut File, length: u64) -> anyhow::Result<()> {
fn ensure_file_length(file: &File, length: u64) -> anyhow::Result<()> {
Ok(file.set_len(length)?)
}