commit-hurd
[Top][All Lists]
Advanced

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

[hurd] 01/06: Make fakerooted access() return real access


From: Samuel Thibault
Subject: [hurd] 01/06: Make fakerooted access() return real access
Date: Tue, 03 Nov 2015 22:43:20 +0000

This is an automated email from the git hooks/post-receive script.

sthibault pushed a commit to branch upstream
in repository hurd.

commit d4a2c3958c79b9582b6541585ad2a72aca7a734a
Author: Svante Signell <address@hidden>
Date:   Tue Oct 20 20:45:48 2015 +0200

    Make fakerooted access() return real access
    
    Various realworld tests would otherwise think they can write to /, while
    they actually can't.
    
    * trans/fakeroot.c (netfs_report_access): Call file_check_access instead of
    returning O_RDWR|O_EXEC when faking mode too.
---
 trans/fakeroot.c | 7 +------
 1 file changed, 1 insertion(+), 6 deletions(-)

diff --git a/trans/fakeroot.c b/trans/fakeroot.c
index 6962810..84b4efc 100644
--- a/trans/fakeroot.c
+++ b/trans/fakeroot.c
@@ -780,12 +780,7 @@ netfs_attempt_write (struct iouser *cred, struct node *np,
 error_t
 netfs_report_access (struct iouser *cred, struct node *np, int *types)
 {
-  struct netnode *nn = netfs_node_netnode (np);
-  if (!(nn->faked & FAKE_MODE))
-    return file_check_access (nn->file, types);
-  else
-    *types = O_RDWR|O_EXEC;
-  return 0;
+  return file_check_access (netfs_node_netnode (np)->file, types);
 }
 
 error_t

-- 
Alioth's /usr/local/bin/git-commit-notice on 
/srv/git.debian.org/git/pkg-hurd/hurd.git



reply via email to

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