Linux-EROFS Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Gao Xiang <xiang@kernel.org>
To: Gao Xiang <hsiangkao@linux.alibaba.com>
Cc: linux-erofs@lists.ozlabs.org
Subject: Re: [PATCH] erofs-utils: mkfs: support tgz streams for tarerofs
Date: Wed, 20 Sep 2023 19:32:12 +0800	[thread overview]
Message-ID: <ZQrYPBo7ykgQe/3v@debian> (raw)
In-Reply-To: <20230919185947.3996843-1-hsiangkao@linux.alibaba.com>

On Wed, Sep 20, 2023 at 02:59:47AM +0800, Gao Xiang wrote:
> Introduce iostream to wrap up the input tarball stream for tarerofs.
> 
> Besides, add bultin tgz support if zlib is linked to mkfs.
> 
> Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>

Apply the following diff to fix pax header regression:

diff --git a/lib/tar.c b/lib/tar.c
index 52036a6..0744972 100644
--- a/lib/tar.c
+++ b/lib/tar.c
@@ -191,7 +191,7 @@ int erofs_iostream_bread(struct erofs_iostream *ios, void *buf, u64 bytes)
 		rem -= ret;
 	} while (rem && ret);
 
-	return rem;
+	return bytes - rem;
 }
 
 int erofs_iostream_lskip(struct erofs_iostream *ios, u64 sz)

      reply	other threads:[~2023-09-20 11:32 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-19 18:59 [PATCH] erofs-utils: mkfs: support tgz streams for tarerofs Gao Xiang
2023-09-20 11:32 ` Gao Xiang [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZQrYPBo7ykgQe/3v@debian \
    --to=xiang@kernel.org \
    --cc=hsiangkao@linux.alibaba.com \
    --cc=linux-erofs@lists.ozlabs.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox