From 307790ce495f23d50156343736cc744957e0ae81 Mon Sep 17 00:00:00 2001 From: Dmitry Date: Sat, 5 Aug 2023 23:07:16 +0300 Subject: [PATCH] fix set_pledged_src_size --- lib/src/db.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/src/db.rs b/lib/src/db.rs index 2336be0..f97e09d 100644 --- a/lib/src/db.rs +++ b/lib/src/db.rs @@ -91,7 +91,7 @@ where let mut zencoder = zstd::stream::raw::Encoder::new(self.compress_lvl).str_err()?; zencoder - .set_pledged_src_size(item_data.len() as u64) + .set_pledged_src_size(Some(item_data.len() as u64)) .str_err()?; self.cur_buf_raw.set_position(0);