diff options
author | Alex Auvolat <alex@adnab.me> | 2020-11-29 17:06:55 +0100 |
---|---|---|
committer | Alex Auvolat <alex@adnab.me> | 2020-11-29 17:07:14 +0100 |
commit | d54f15b2c6794eacee82d3900c50dbfb086f8c79 (patch) | |
tree | 26d1b91c922fa1c22edf506b1388e83506af6fcb /src | |
parent | 3f18aa6f1def52d61a4fc3bbb667d1f0911665ed (diff) | |
download | garage-d54f15b2c6794eacee82d3900c50dbfb086f8c79.tar.gz garage-d54f15b2c6794eacee82d3900c50dbfb086f8c79.zip |
Small optimisation
Diffstat (limited to 'src')
-rw-r--r-- | src/api/s3_put.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/api/s3_put.rs b/src/api/s3_put.rs index 09c3cdbe..9c4d625c 100644 --- a/src/api/s3_put.rs +++ b/src/api/s3_put.rs @@ -248,7 +248,7 @@ impl BodyChunker { body, read_all: false, block_size, - buf: VecDeque::new(), + buf: VecDeque::with_capacity(2 * block_size), } } async fn next(&mut self) -> Result<Option<Vec<u8>>, GarageError> { |