chroot: better solution for bug found in previous commit