Skip to content

Commit 6d2a6f3

Browse files
author
Edward Thomson
authored
Apply suggestions from code review
1 parent b34aaf6 commit 6d2a6f3

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/ignore.c

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -141,14 +141,14 @@ static int does_negate_rule(int *out, git_vector *rules, git_attr_fnmatch *match
141141
if (git_buf_oom(&buf))
142142
goto out;
143143

144-
/* if rule isn't for full path we match without PATHNAME flag
144+
/*
145+
* if rule isn't for full path we match without PATHNAME flag
145146
* as lines like *.txt should match something like dir/test.txt
146147
* requiring * to also match /
147-
*/
148+
*/
148149
effective_flags = wildmatch_flags;
149-
if (!(rule->flags & GIT_ATTR_FNMATCH_FULLPATH)) {
150+
if (!(rule->flags & GIT_ATTR_FNMATCH_FULLPATH))
150151
effective_flags &= ~WM_PATHNAME;
151-
}
152152

153153
/* if we found a match, we want to keep this rule */
154154
if ((wildmatch(git_buf_cstr(&buf), path, effective_flags)) == WM_MATCH) {

0 commit comments

Comments
 (0)