Skip to content

attr directory matching regression

Nguyễn Thái Ngọc Duy git 1 version In review

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest4 patches 3 repliesIn review

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/4wildmatch: do not require "text" to be NUL-terminatedwildmatch.c wildmatch.h+34 -200 replies
2/4attr.c: fix pattern{,len} inconsistency in struct match_attrattr.c dir.h+3 -10 replies
3/4dir.c: make match_{base,path}name respect {basename,path}lendir.c+8 -50 replies
4/4attr.c: fix matching "subdir" without the trailing slashattr.c t/t5002-archive-attr-pattern.sh+15 -22 replies

Reviews trailers per patch

None of the 4 patches has a Reviewed-by or Acked-by.

PatchJeff King
1/4
2/4
3/4
4/4Reported-and-analyzed-by

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/4] attr directory matching regression

I think the fix is something like this. There is still one thing I'd like to do: make this code not rely on NUL for terminating the patterns. That should remove the ugly "p[len] = '\0'" in prepare_attr_stack() 4/4 and and the reallocation in add_exclude() (in current code). But let's deal with the regression first.

Nguyễn Thái Ngọc Duy (4):
wildmatch: do not require "text" to be NUL-terminated attr.c: fix pattern{,len} inconsistency in struct match_attr dir.c: make match_{base,path}name respect {basename,path}len attr.c: fix matching "subdir" without the trailing slash

 attr.c                          | 11 ++++++++++-
 dir.c                           | 13 ++++++++-----
 dir.h                           |  2 +-
 t/t5002-archive-attr-pattern.sh |  6 ++++++
 wildmatch.c                     | 43 ++++++++++++++++++++++++-----------------
 wildmatch.h                     | 11 +++++++++--
 6 files changed, 59 insertions(+), 27 deletions(-)
Signature · 1 line
1.8.2.82.gc24b958