diff --git a/src/write.rs b/src/write.rs index b60386fb..529f3e82 100644 --- a/src/write.rs +++ b/src/write.rs @@ -1456,7 +1456,7 @@ impl ZipWriter { let src_index = self.index_by_name(src_name)?; let mut dest_data = self.files[src_index].to_owned(); dest_data.file_name = dest_name.to_string().into(); - dest_data.file_name_raw = dest_name.to_string().into_boxed_bytes(); + dest_data.file_name_raw = dest_name.to_string().into_bytes().into(); self.insert_file_data(dest_data)?; Ok(()) }