aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/api/s3_put.rs10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/api/s3_put.rs b/src/api/s3_put.rs
index f5607c9f..d2702940 100644
--- a/src/api/s3_put.rs
+++ b/src/api/s3_put.rs
@@ -302,8 +302,14 @@ impl BodyChunker {
if self.buf.len() == 0 {
Ok(None)
} else {
- let mut iter = FastCDC::with_eof(self.buf.make_contiguous(), self.min_block_size, self.avg_block_size, self.max_block_size, self.read_all);
- if let Some(Chunk {length, ..}) = iter.next() {
+ let mut iter = FastCDC::with_eof(
+ self.buf.make_contiguous(),
+ self.min_block_size,
+ self.avg_block_size,
+ self.max_block_size,
+ self.read_all,
+ );
+ if let Some(Chunk { length, .. }) = iter.next() {
let block = self.buf.drain(..length).collect::<Vec<u8>>();
Ok(Some(block))
} else {