diff --git a/Cargo.lock b/Cargo.lock index 583238c..928fb90 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -605,7 +605,7 @@ dependencies = [ [[package]] name = "markov" -version = "0.2.0" +version = "0.3.0" dependencies = [ "cfg-if 1.0.0", "futures", diff --git a/src/save.rs b/src/save.rs index fa8461c..a824774 100644 --- a/src/save.rs +++ b/src/save.rs @@ -55,6 +55,7 @@ async fn save_now_to(chain: &Chain, to: impl AsRef) -> io::Result< let mut file = AsyncWriteCompressor::new(file, PreferencesBuilder::new() .compression_level(lz4f::CLEVEL_HIGH).build())?; file.write_all(&chain[..]).await?; + file.flush().await?; file.shutdown().await?; Ok(()) }