some clippy fixups
Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
This commit is contained in:
@ -162,7 +162,7 @@ impl <R: Read + BufRead> CatalogBlobReader<R> {
|
||||
write!(out, " {} {}", size, dt.to_rfc3339_opts(chrono::SecondsFormat::Secs, false))?;
|
||||
}
|
||||
|
||||
write!(out, "\n")?;
|
||||
writeln!(out)?;
|
||||
std::io::stdout().write_all(&out)?;
|
||||
|
||||
Ok(())
|
||||
|
@ -99,8 +99,8 @@ impl Chunker {
|
||||
chunk_size_max: chunk_size_avg << 2,
|
||||
_chunk_size_avg: chunk_size_avg,
|
||||
_discriminator: discriminator,
|
||||
break_test_mask: break_test_mask,
|
||||
break_test_minimum: break_test_minimum,
|
||||
break_test_mask,
|
||||
break_test_minimum,
|
||||
window: [0u8; CA_CHUNKER_WINDOW_SIZE],
|
||||
}
|
||||
}
|
||||
|
@ -217,12 +217,12 @@ impl DataChunk {
|
||||
bail!("encrypted chunk too small ({} bytes).", data.len());
|
||||
}
|
||||
|
||||
let chunk = DataChunk { digest: digest, raw_data: data };
|
||||
let chunk = DataChunk { digest, raw_data: data };
|
||||
|
||||
Ok(chunk)
|
||||
} else if magic == COMPRESSED_CHUNK_MAGIC_1_0 || magic == UNCOMPRESSED_CHUNK_MAGIC_1_0 {
|
||||
|
||||
let chunk = DataChunk { digest: digest, raw_data: data };
|
||||
let chunk = DataChunk { digest, raw_data: data };
|
||||
|
||||
Ok(chunk)
|
||||
} else {
|
||||
|
@ -275,8 +275,8 @@ impl <S: ReadChunk> BufferedDynamicReader<S> {
|
||||
let archive_size = index.chunk_end(index.index_entries - 1);
|
||||
Self {
|
||||
store,
|
||||
index: index,
|
||||
archive_size: archive_size,
|
||||
index,
|
||||
archive_size,
|
||||
read_buffer: Vec::with_capacity(1024*1024),
|
||||
buffered_chunk_idx: 0,
|
||||
buffered_chunk_start: 0,
|
||||
@ -456,7 +456,7 @@ impl DynamicIndexWriter {
|
||||
Ok(Self {
|
||||
store,
|
||||
_lock: shared_lock,
|
||||
writer: writer,
|
||||
writer,
|
||||
closed: false,
|
||||
filename: full_path,
|
||||
tmp_filename: tmp_path,
|
||||
|
@ -453,8 +453,8 @@ impl <S: ReadChunk> BufferedFixedReader<S> {
|
||||
let archive_size = index.size;
|
||||
Self {
|
||||
store,
|
||||
index: index,
|
||||
archive_size: archive_size,
|
||||
index,
|
||||
archive_size,
|
||||
read_buffer: Vec::with_capacity(1024*1024),
|
||||
buffered_chunk_idx: 0,
|
||||
buffered_chunk_start: 0,
|
||||
|
Reference in New Issue
Block a user