parse_pathspec: make sure the prefix part is wildcard-free
Prepending prefix to pathspec is a trick to workaround the fact that commands can be executed in a subdirectory, but all git commands run at worktree's root. The prefix part should always be treated as literal string. Make it so. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
b3920bbdc5
commit
645a29c40a
@ -21,7 +21,7 @@ struct pathspec {
|
||||
const char *match;
|
||||
const char *original;
|
||||
unsigned magic;
|
||||
int len;
|
||||
int len, prefix;
|
||||
int nowildcard_len;
|
||||
int flags;
|
||||
} *items;
|
||||
|
Reference in New Issue
Block a user