Svante Signell, le Tue 09 Jun 2015 16:46:14 +0200, a écrit : > On Tue, 2015-06-09 at 14:20 +0200, Samuel Thibault wrote: > > Svante Signell, le Tue 09 Jun 2015 11:41:01 +0200, a écrit : > > > On Tue, 2015-06-09 at 11:11 +0200, Samuel Thibault wrote: > > > > > > > So the package is actually doing something stupid (yes, that's what you > > > > should have written in your mail to explain what is happening, actually > > > > :) ). But it does work as root as specified by POSIX, so we have to > > > > support it. > > > > > > Yes I think there is a package bug (it's up to the package maintainer to > > > write good code, not me pointing fingers): > > > > Well, the code is supposed to be run by root, so it's actually sorta > > "correct" :) > > The difference is that real root can change the directory mode to > drw-r--r-- and still access everything below, but fakeroot has to do at > least drwxr--r- for anybody except root itself to read that directory.
Yes, that's what I meant. > New patch attached using the IS_ISDIR macro. Better now? Yes, except that > - if (nn->openmodes & O_EXEC) > - real_mode |= S_IXUSR; > + real_mode = mode | S_IRUSR | S_IWUSR; > + if (S_ISDIR (mode)) > + real_mode |= S_IXUSR; This should be 2-space indentation like the rest of the file. I'm also wondering whether we'd want to set IXUSR when openmodes & O_EXEC. BTW, I guess you have tested the patch? Samuel