erofs-utils: fix chunk-based image handling without real data
PATCH 1/1 erofs-utils: fix chunk-based image handling without real data
Otherwise it will report:
<I> erofs: total metadata: 982 blocks
<E> erofs: Could not format the device : [Error 5] Input/output error
Fixes 03cbf7b8f7f7 ("erofs-utils: mkfs: support chunk-based uncompressed files")
Signed-off-by Gao Xiang <[email protected]>
--- lib/blobchunk.c | 2 ++ 1 file changed, 2 insertions(+)
lib/blobchunk.c +2 -0
@@ -276,6 +276,8 @@ int erofs_blob_remap(void)erofs_bdrop (bh_devt, false);return 0 ; } +if (!length)/* bail out if there is no chunked data */ +return 0 ; bh =erofs_balloc (DATA , length,0 ,0 );if (IS_ERR (bh))return PTR_ERR (bh);
Signature · 1 line
2.24.4