# HG changeset patch # User Franz Glasner # Date 1661064620 -7200 # Node ID 4a0cb73945a81d3d4bceb0ec7204dc924edbebb6 # Parent 379d3178f3ce205a470130b74f163fd681517c6b Use "read -r" for when mounting/unmounting diff -r 379d3178f3ce -r 4a0cb73945a8 sbin/fjail --- a/sbin/fjail Sun Aug 21 08:35:18 2022 +0200 +++ b/sbin/fjail Sun Aug 21 08:50:20 2022 +0200 @@ -395,7 +395,7 @@ { echo "ERROR: root dataset does not exist" >&2; return 1; } zfs list -H -o name,mountpoint,canmount,mounted -s mountpoint -t filesystem -r "${_dsname}" | \ - while IFS=$'\t' read _name _mp _canmount _mounted ; do + while IFS=$'\t' read -r _name _mp _canmount _mounted ; do # Skip filesystems that are already mounted [ "${_mounted}" = "yes" ] && continue # Skip filesystems that must not be mounted @@ -455,7 +455,7 @@ mount -t zfs -p | \ grep -E "^${_dsname}(/|\s)" | \ sort -n -r | \ - while IFS=' '$'\t' read _name _mp _rest ; do + while IFS=' '$'\t' read -r _name _mp _rest ; do echo "Umounting ${_name} on ${_mp}" umount "${_mp}" || return 1 done