bug-findutils
[Top][All Lists]
Advanced

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

Re: [patch] find/pred.c: basename versus base_name.


From: Bas van Gompel
Subject: Re: [patch] find/pred.c: basename versus base_name.
Date: Thu, 3 Feb 2005 23:29:25 +0100 (MET)
User-agent: slrn/0.9.8.1 (Win32) Hamster/2.0.6.0 Korrnews/4.2

Op Thu, 3 Feb 2005 22:38:58 +0300 schreef Dmitry V. Levin
in <address@hidden>:
[...]
:  On Thu, Feb 03, 2005 at 08:12:07PM +0100, Bas van Gompel wrote:
[...]

: > testcase:
: > cd /tmp
: > find  /usr/bin -mindepth 0 -maxdepth 0 -type d \
: > -exec pwd \; \
: > -exec echo {} \; \
: > -execdir pwd \; \
: > -execdir echo {} \; \
: > -execdir ls -ld {} \;

[current output, with (AIUI) wrong pwd in -execdir output]

: > I was, on reading (the security section of) the info page, expecting:
: > /tmp
: > /usr/bin
: > /usr
: > ./bin
: > <listing of ./bin, starting from /usr>

:  I expect (and my change makes) following behavior:
:  /tmp
:  /usr/bin
:  /tmp
:  /usr/bin
:  <listing of /usr/bin directory without its contents>

So, your change makes -execdir behave identical to -exec?
If that is the case, it is wrong. See:
$ info '(find)Security Considerations for find'
(especially the last paragraph of section 8.2.2.)

[...]

L8r,

Buzz.
-- 
  ) |  | ---/ ---/  Yes, this | This message consists of true | I do not
--  |  |   /    /   really is |   and false bits entirely.    | mail for
  ) |  |  /    /    a 72 by 4 +-------------------------------+ any1 but
--  \--| /--- /---  .sigfile. |   |perl -pe "s.u(z)\1.as."    | me. 4^re




reply via email to

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