Dear Maintainer,
I would like to report an issue with the ischroot utility from debianutils
where it incorrectly returns 0 when executed
inside an unshared mount namespace, which causes issues with hibernation and
wake-up functionality when generating initrd in an unshare environment.
Steps to Reproduce:
$ sudo unshare --mount bash
$ ischroot; echo $?
Observe that the exit code is 0, which indicates that ischroot incorrectly
detects the environment as a chroot.
Expected Behavior:
ischroot should return a non-zero value unless the process is actually inside a
chroot. Simply creating a new mount namespace using unshare does not constitute
a chroot environment.