From fbeba9696c4732eb72aaa2de9e26f15cf51dbefe Mon Sep 17 00:00:00 2001 From: "Darrick J. Wong" Date: Tue, 11 Oct 2022 18:45:44 -0700 Subject: [PATCH] populate: require e2image before populating Use $E2IMAGE_PROG, not e2image, and check that it exists before proceeding. Signed-off-by: Darrick J. Wong Reviewed-by: Zorro Lang Signed-off-by: Zorro Lang --- common/populate | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/common/populate b/common/populate index 09b86af2..5a7476fe 100644 --- a/common/populate +++ b/common/populate @@ -18,6 +18,7 @@ _require_populate_commands() { ;; ext*) _require_command "$DUMPE2FS_PROG" "dumpe2fs" + _require_command "$E2IMAGE_PROG" "e2image" ;; esac } @@ -874,7 +875,7 @@ _scratch_populate_restore_cached() { return $res ;; "ext2"|"ext3"|"ext4") - e2image -r "${metadump}" "${SCRATCH_DEV}" + $E2IMAGE_PROG -r "${metadump}" "${SCRATCH_DEV}" ret=$? test $ret -ne 0 && return $ret -- 2.39.5