]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
fix zstd magic header
authortpgxyz <tpgxyz@gmail.com>
Wed, 18 Apr 2018 18:57:33 +0000 (20:57 +0200)
committerHarald Hoyer <harald@hoyer.xyz>
Thu, 19 Apr 2018 04:31:23 +0000 (06:31 +0200)
modules.d/99img-lib/img-lib.sh

index 437858120da421f0805d72e7a054560e77d3c635..f47741533e0fa5ce7754d8551ef07b0b49165070 100755 (executable)
@@ -8,7 +8,7 @@
 # works with stdin if $1 is not set.
 det_archive() {
     # NOTE: echo -e works in ash and bash, but not dash
-    local bz="BZh" xz="$(echo -e '\xfd7zXZ')" gz="$(echo -e '\x1f\x8b')" zs="$(echo -e '0xFD2FB528')"
+    local bz="BZh" xz="$(echo -e '\xfd7zXZ')" gz="$(echo -e '\x1f\x8b')" zs="$(echo -e '\x28\xB5\x2F\xFD')"
     local headerblock="$(dd ${1:+if=$1} bs=262 count=1 2>/dev/null)"
     case "$headerblock" in
         $xz*) echo "xz" ;;