bug-hurd
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: RFC: [PATCH] trans/fakeroot.c


From: Svante Signell
Subject: Re: RFC: [PATCH] trans/fakeroot.c
Date: Tue, 09 Jun 2015 16:46:14 +0200

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.

> You also need to fix the indentation.

Fixed :)

> > +    if ((real_mode & S_IFDIR) 
> 
> I don't think it's so simple, see the precise S_IFMT bit matter. That
> should most probably be rather an S_ISDIR call.

New patch attached using the IS_ISDIR macro. Better now?

Attachment: trans_fakeroot_chmod.patch
Description: Text Data


reply via email to

[Prev in Thread] Current Thread [Next in Thread]