bug-findutils
[Top][All Lists]
Advanced

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

[bugs #11879] all mount-points lstat()-ed, but shouldn't be


From: James Youngman
Subject: [bugs #11879] all mount-points lstat()-ed, but shouldn't be
Date: Sat, 12 Feb 2005 21:16:34 +0000
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.7.5) Gecko/20050210 Firefox/1.0 (Debian package 1.0+dfsg.1-6)

Update of bugs #11879 (project findutils):

                  Status:                    None => Fixed                  

    _______________________________________________________

Follow-up Comment #2:

I have just checked the attached patch into CVS.  This resolves the problem
by using open(..., O_NOFOLLOW) followed by fchdir() instead of chdir().  This
eliminates the need to lstat() the target directory before and after, hence
eliminating the need for the mounted device list.  However, fchdir() does not
always work on all systems where the system call exists, and so in these
circumstances we fall back on the previous implementation (enumerating the
mounted devices at that point).  



This is, to say the least, a significant change to the way that find works. 
The regression test suite passes, but then it only has 19 tests.  



Please test this change thoroughly and let me know how it works for you.  You
can do this either by downloading the code from CVS (which I would recommend)
or by applying the attached patch (against findutils-4.2.17).  If I get
negative feedback I can redo the fix or whatever, but if I get positive
feedback we can move towards another release. 


    _______________________________________________________

Additional Item Attachment:

File name: findutils-4.2.17-nofollow.patch Size:20 KB
First proposed fix for bug #11879 (patch against 4.2.17 release)
<http://savannah.gnu.org/bugs/download.php?item_id=11879&item_file_id=2184>

    _______________________________________________________

This item URL is:

  <http://savannah.gnu.org/bugs/?func=detailitem&item_id=11879>

_______________________________________________
  Message sent via/by Savannah
  http://savannah.gnu.org/





reply via email to

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