GNU bug report logs - #6297
file-expand-wildcards permission error on top-level mount point

Previous Next

Package: emacs;

Reported by: MON KEY <monkey <at> sandpframing.com>

Date: Fri, 28 May 2010 22:32:02 UTC

Severity: minor

Tags: fixed

Fixed in version 24.1

Done: Lars Magne Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: MON KEY <monkey <at> sandpframing.com>
To: bug-gnu-emacs <at> gnu.org
Subject: file-expand-wildcards permission error on top-level mount point
Date: Fri, 28 May 2010 18:30:53 -0400
file-expand-wildcards permission error on top-level mount point

Evaluating (file-expand-wildcards "/*/SOME-DIR/*")

Where the first kleene's target is a mount point e.g.:
 "/mnt/SOME-DIR/*"

Signals this error:
 (file-error "Opening directory" "permission denied" "/lost+found/")

I'm not sure where the error is getting signalled whether its happening
under the root mount point e.g. "/" or if its occuring under

 "/mnt/God-knows-where/..."

On this sytem "lost+found" is the directory that was placed in an ext4
partition for recovery purposes.

It appears that `file-expand-wildcards' gets trounced via
`directory-files' which is signaling an error if the permissions
aren't kosher somewhere.

Shouldn't one of these guys be checking with `file-readable-p' or
`file-attributes' at some such at some point whilst walking the
filesytem?

The error is signalled here too:

 (file-expand-wildcards "/*/etc/*.conf")

Whereas this works fine:

 (file-expand-wildcards "/etc/*.conf")

which seems odd because in each case (error or not) the permissions
can't be more than root:root i.e. the file-list returnd by the last
form are all root:root.

Surely one shouldn't need to be considering umask/dmask/setuid
etc. just to use this function?


On a GNU Emacs 23.2.1
(i686-pc-linux-gnu, GTK+ Version 2.20.0) of 2010-05-10

-- 
/s_P\




This bug report was last modified 14 years and 21 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.