diff --git a/src/paccache.sh.in b/src/paccache.sh.in index af901f4..1311fd7 100644 --- a/src/paccache.sh.in +++ b/src/paccache.sh.in @@ -391,7 +391,8 @@ candidates=("${candtemp[@]}") unset candtemp # do this before we destroy anything -totalsaved=$(@SIZECMD@ "${candidates[@]}" | awk '{ sum += $1 } END { print sum }') +totalsaved=$(printf '%s\0' "${candidates[@]}" | xargs -0 @SIZECMD@ | + awk '{ sum += $1 } END { print sum }') # Exit immediately if a pipeline returns non-zero. set -o errexit