[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#784234: [PATCH initramfs-tools 3/3] hooks/fsck: Use 'command' to find fsck.<type>



fsck doesn't require that fsck.<type> is installed under /sbin and
neither should we.

Closes: #784234
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
---
 hooks/fsck | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/hooks/fsck b/hooks/fsck
index f80f037..8570705 100755
--- a/hooks/fsck
+++ b/hooks/fsck
@@ -117,7 +117,7 @@ for type in $fsck_types; do
 		continue
 	fi
 
-	prog="/sbin/fsck.${type}"
+	prog="$(command -v fsck.${type})"
 	if [ -h "$prog" ]; then
 		link=$(readlink -f "$prog")
 		copy_exec "$link"
-- 
Ben Hutchings
Theory and practice are closer in theory than in practice.
                                - John Levine, moderator of comp.compilers

Attachment: signature.asc
Description: This is a digitally signed message part


Reply to: