bug#55344: ftw thinks readable directories are unreadable if "other" don't have read permission

angry rectangle <[email protected]>
Newsgroups gmane.lisp.guile.bugs
Message-ID <[email protected]>
(hmm... resending this because it didnt work. hopefully i'm doing it right this time.)

It looks like guile's compiler and optimizer could be replacing the `getuid' and `setuid' calls with constant, compile-time values.

Here is a test I performed:
1. Make directory with 770 owned by root and the `guixbuild' group. When guile is compiled with guix, I think the process is done under one of the guixbuilder<XX> users who have the `guixbuild' group.
2. Run guile under my regular user.
3. Try to `ftw' that directory. ftw detects it as a readable directory and then ends up throwing a "permission denied" error because it's not actually readable.

If I compile guile manually under my regular user and try ftw on a different user, I observe the results that support my conclusion.

System info:
Guile 3.0.8.13-cc455
guix on amd64
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.