[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug #27032] find fails to find a file that ls can list
From: |
PG |
Subject: |
[bug #27032] find fails to find a file that ls can list |
Date: |
Wed, 15 Jul 2009 07:54:18 +0000 |
User-agent: |
Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.0.11) Gecko/2009060309 Ubuntu/9.04 (jaunty) Firefox/3.0.11 |
URL:
<http://savannah.gnu.org/bugs/?27032>
Summary: find fails to find a file that ls can list
Project: findutils
Submitted by: pgscooter
Submitted on: Wed 15 Jul 2009 07:54:16 AM GMT
Category: find
Severity: 3 - Normal
Item Group: Wrong result
Status: None
Privacy: Public
Assigned to: None
Originator Name:
Originator Email:
Open/Closed: Open
Discussion Lock: Any
Release: 4.4.0
Fixed Release: None
_______________________________________________________
Details:
the command "ls" can find a file that find cannot. I think that find should
either find files of this type by default, or at least have an option to do
so. From what I understand, find cannot find the file because it attempts to
cd into the directory before listing, instead of just listing the directory.
It is possible that you have permission to do one but not the other.
To reproduce the situation, please see the following commands and output:
address@hidden:/home/xinwei/bugreport# ls -l
total 4
d---r--r-- 2 root root 4096 2009-07-05 13:27 protected
address@hidden:/home/xinwei/bugreport# ls -l protected
total 0
-rw-r--r-- 1 xinwei xinwei 0 2009-07-05 13:27 canttouchthis
address@hidden:/home/xinwei/bugreport# exit
address@hidden:~/bugreport$ ls -l protected/
ls: cannot access protected/canttouchthis: Permission denied
total 0
-????????? ? ? ? ? ? canttouchthis
address@hidden:~/bugreport$ find ./ -name canttouchthis
address@hidden:~/bugreport$ sudo !!
sudo find ./ -name canttouchthis
./protected/canttouchthis
address@hidden:~/bugreport$
-----------------------------------------------------------
here is a copy of some further conversation on this exact topic:
Posted by James Youngman <address@hidden>
OpenSolaris find doesn't either:
flare:~/tmp$ find ft/tmp -ls
347455 4 drwxr-xr-x 3 james 1001 4096 Jul 8 09:54 ft/tmp
347457 4 drw-r--r-- 2 james 1001 4096 Jul 8 09:54
ft/tmp/nonexecutable
find: cannot read dir ft/tmp/nonexecutable/: Permission denied
flare:~/tmp$ ls -l ft/tmp/nonexecutable
ft/tmp/nonexecutable/foo: Permission denied
total 0
$ find ft -print
ft
ft/tmp
ft/tmp/nonexecutable
find: cannot read dir ft/tmp/nonexecutable/: Permission denied
flare:~/tmp$ uname -a
SunOS flare.spiral-arm.org 5.11 snv_101b i86pc i386 i86xpv
Thank you
_______________________________________________________
Reply to this item at:
<http://savannah.gnu.org/bugs/?27032>
_______________________________________________
Message sent via/by Savannah
http://savannah.gnu.org/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [bug #27032] find fails to find a file that ls can list,
PG <=