From 3048b6bcfee0a944d7fc0732cf97d9cc23ce955c Mon Sep 17 00:00:00 2001 From: Luca Mondada <72734770+lmondada@users.noreply.github.com> Date: Fri, 29 Sep 2023 12:10:55 +0200 Subject: [PATCH] Update src/rewrite/ecc_rewriter.rs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Agustín Borgna <121866228+aborgna-q@users.noreply.github.com> --- src/rewrite/ecc_rewriter.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/rewrite/ecc_rewriter.rs b/src/rewrite/ecc_rewriter.rs index dba5d3cc..8f0a5a8d 100644 --- a/src/rewrite/ecc_rewriter.rs +++ b/src/rewrite/ecc_rewriter.rs @@ -129,7 +129,8 @@ impl ECCRewriter { ) -> Result { let mut file_name = PathBuf::from(name.as_ref()); file_name.set_extension("rwr"); - let mut file = File::create(&file_name)?; + let file = File::create(&file_name)?; + let mut file = io::BufWriter::new(file); self.save_binary_io(&mut file)?; Ok(file_name) }