From 93b9d6ca0562d8a2fcc44bd2d7d73dfc1cba9191 Mon Sep 17 00:00:00 2001 From: Stefano Brivio Date: Wed, 30 Mar 2022 04:26:09 +0200 Subject: mbuto: Fix lz4 command line lz4 needs an explicit output file if we're not compressing to stdout. Signed-off-by: Stefano Brivio --- mbuto | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/mbuto b/mbuto index 45a12e5..23eaf6e 100755 --- a/mbuto +++ b/mbuto @@ -344,9 +344,12 @@ cpio_compress() { [ "${COMPRESS}" = "lzo" ] && __cmd="lzop" || __cmd="${COMPRESS}" cmd_check "${__cmd}" - [ "${__cmd}" = "lz4" ] && __opt="-l" || __opt="-S .lz4" + if [ "${__cmd}" = "lz4" ]; then + "${__cmd}" -l -f -q -9 "${1}" "${1}.lz4" + else + "${__cmd}" -f -q -9 -S .lz4 "${1}" + fi - "${__cmd}" ${__opt} -f -q -9 "${1}" mv "${1}.lz4" "${1}" return -- cgit v1.2.3