[Top][All Lists]

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

Re: fakeroot problem

From: Marcus Brinkmann
Subject: Re: fakeroot problem
Date: Sat, 11 May 2002 23:43:11 +0200
User-agent: Mutt/1.3.28i

On Sat, May 11, 2002 at 04:17:25PM -0400, Roland McGrath wrote:
> Oh yeah, the patch:

> +  err = netfs_validate_stat (netfs_root_node, 0);
> +  if (err)
> +    error (6, err, "Cannot stat underlying node");
> +
> +  netfs_root_node->nn_stat.st_mode &= ~(S_IPTRANS | S_IATRANS);
> +  netfs_root_node->nn_stat.st_mode |= S_IROOT;
> +  netfs_root_node->nn->faked |= FAKE_MODE;
> +

This looks like a better place an dnicer way to do it.

On Sat, May 11, 2002 at 04:17:14PM -0400, Roland McGrath wrote:
> The intent of fakeroot is to be unaware of translators in the underlying
> directory tree.

Thanks for all the details, but it makes me wonder if you missed the

if (np == netfs_root_node)

in my patch, which makes sure that only the translator flags for the root
node are cleared, none else.  I am happy to test your patch as well, but
except for the S_IROOT it should be functionally exactly identical, or am I
missing something?

> To make cases like the current state less confusing, perhaps netfs (and
> diskfs) should do something special for an EOPNOTSUPP return from
> *_get_translator in lookup/getroot.  It will only come up there if
> S_IPTRANS is set, which the *_validate_stat hook should only set if
> *_get_translator is going to work right.  So it's an internal bogosity for
> it then to return EOPNOTSUPP.  It could translate that to EIO or
> EGRATUITOUS or something, or just use an assert.

Mmh, yeah, I agree, it is a bit schizophrenic.


`Rhubarb is no Egyptian god.' Debian http://www.debian.org brinkmd@debian.org
Marcus Brinkmann              GNU    http://www.gnu.org    marcus@gnu.org

reply via email to

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