diff options
Diffstat (limited to 'src/chroot-tools')
-rwxr-xr-x | src/chroot-tools/chcleanup | 2 | ||||
-rwxr-xr-x | src/chroot-tools/librechroot | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/chroot-tools/chcleanup b/src/chroot-tools/chcleanup index 6432d5b..bfb65ce 100755 --- a/src/chroot-tools/chcleanup +++ b/src/chroot-tools/chcleanup @@ -79,7 +79,7 @@ cp /repo/repo.db /var/lib/pacman/sync/repo.db # Setup the temporary directory TEMPDIR="$(mktemp --tmpdir -d ${0##*/}.XXXXXXXXXX)" -trap "rm -rf '$TEMPDIR'" EXIT +trap "rm -rf -- $(printf '%q' "$TEMPDIR")" EXIT cp -a /var/lib/pacman/sync "${TEMPDIR}/" pkglist="${TEMPDIR}"/pkglist.txt diff --git a/src/chroot-tools/librechroot b/src/chroot-tools/librechroot index d8e76ac..6be9f09 100755 --- a/src/chroot-tools/librechroot +++ b/src/chroot-tools/librechroot @@ -371,7 +371,7 @@ main() { arch-nspawn "$copydir" bash -c 'pacman -Syu --noconfirm' ;; clean-pkgs) - trap "rm -f '$copydir'/bin/chcleanup '$copydir'/chrootexec" EXIT + trap "rm -f -- $(printf '%q ' "$copydir"/{bin/chcleanup,chrootexec})" EXIT install -m755 "$(librelib chroot/chcleanup)" "$copydir/bin/chcleanup" printf '%s\n' \ '#!/bin/bash' \ |