diff options
author | Jim Meyering <meyering@redhat.com> | 2010-03-28 17:32:48 +0200 |
---|---|---|
committer | Jim Meyering <meyering@redhat.com> | 2010-03-28 20:59:00 +0200 |
commit | da3d9ebff4400a131448b1548bc5e12d8e701ae3 (patch) | |
tree | c8b4c86ac152700138e942891597cc566c7c9d01 /lib | |
parent | c03209e3bb4a64a4ceacf3c02e6ba69cb1457d4d (diff) | |
download | grep-da3d9ebff4400a131448b1548bc5e12d8e701ae3.tar.gz |
grep -r: fix --include with non-globs
* lib/savedir.c (savedir): Fix logic error. Introduced by commit
bf3bd92c, "build: adapt to the newer exclude API we now get from gnulib"
* tests/include-exclude: Test for this bug by exercising --include, too.
* NEWS (Bug fixes): Mention it.
Reported by Philipp Kohlbecher in http://savannah.gnu.org/bugs/?29358
Diffstat (limited to 'lib')
-rw-r--r-- | lib/savedir.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/savedir.c b/lib/savedir.c index 94e5f121..53f8c7be 100644 --- a/lib/savedir.c +++ b/lib/savedir.c @@ -112,7 +112,7 @@ savedir (const char *dir, off_t name_size, struct exclude *included_patterns, && !isdir1 (dir, dp->d_name)) { if (included_patterns - && !excluded_file_name (included_patterns, dp->d_name)) + && excluded_file_name (included_patterns, dp->d_name)) continue; if (excluded_patterns && excluded_file_name (excluded_patterns, dp->d_name)) |