5
0
mirror of git://git.proxmox.com/git/pxar.git synced 2025-02-03 21:47:00 +03:00

fix async Encoder::create

Signed-off-by: Wolfgang Bumiller <w.bumiller@proxmox.com>
This commit is contained in:
Wolfgang Bumiller 2020-03-23 10:17:30 +01:00
parent 327e33f21b
commit a889559e32

View File

@ -49,7 +49,7 @@ impl<'a, T: tokio::io::AsyncWrite + 'a> Encoder<'a, TokioWriter<T>> {
#[cfg(feature = "tokio-fs")]
impl<'a> Encoder<'a, TokioWriter<tokio::fs::File>> {
/// Convenience shortcut for `File::create` followed by `Encoder::from_tokio`.
pub fn create<'b, P: AsRef<Path>>(
pub async fn create<'b, P: AsRef<Path>>(
path: P,
metadata: &'b Metadata,
) -> io::Result<Encoder<'a, TokioWriter<tokio::fs::File>>> {