[PATCH 2 of 2] grep: -r should recurse into symlinks to directories
Thomas De Schampheleire
patrickdepinguin at gmail.com
Thu Aug 28 13:02:45 UTC 2014
On Tue, Jul 29, 2014 at 10:45 AM, Thomas De Schampheleire
<patrickdepinguin at gmail.com> wrote:
> The command
> grep -r . symlink_to_dir
> should recurse into the directory pointed to by symlink_to_dir.
> This patch fixes grep to implement this case.
> This also fixes the newly added test in the testsuite.
>
> Signed-off-by: Thomas De Schampheleire <thomas.de.schampheleire at gmail.com>
>
> ---
> findutils/grep.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff -r 66406add5e60 -r 8c87fa8591be findutils/grep.c
> --- a/findutils/grep.c Mon Jul 28 16:33:41 2014 +0200
> +++ b/findutils/grep.c Mon Jul 28 16:38:36 2014 +0200
> @@ -668,7 +668,7 @@
> int matched = 0;
> recursive_action(dir,
> /* recurse=yes */ ACTION_RECURSE |
> - /* followLinks=no */
> + /* followLinks=yes */ ACTION_FOLLOWLINKS |
> /* depthFirst=yes */ ACTION_DEPTHFIRST,
> /* fileAction= */ file_action_grep,
> /* dirAction= */ NULL,
ping?
More information about the busybox
mailing list