author | Daniel Barkalow <barkalow@iabervon.org> | |
Tue, 18 Mar 2008 02:05:23 +0000 (22:05 -0400) | ||
committer | Junio C Hamano <gitster@pobox.com> | |
Wed, 26 Mar 2008 07:10:55 +0000 (00:10 -0700) | ||
commit | c091b3d415f95d3e4e62acddb084e211af46acbf | |
tree | d7370870e12f5dc2b4bf2a35858723c0d0c9c030 | tree | snapshot |
parent | 71a5099b647267d509e43f2c41483ca79af49d9f | commit | diff |
Tighten refspec processing
This changes the pattern matching code to not store the required final
/ before the *, and then to require each side to be a valid ref (or
empty). In particular, any refspec that looks like it should be a
pattern but doesn't quite meet the requirements will be found to be
invalid as a fallback non-pattern.
This was cherry picked from commit ef00d15 (Tighten refspec processing,
2008-03-17), and two fix-up commits 46220ca (remote.c: Fix overtight
refspec validation, 2008-03-20) and 7d19da4 (refspec: allow colon-less
wildcard "refs/category/*", 2008-03-25) squashed in.
Signed-off-by: Daniel Barkalow <barkalow@iabervon.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This changes the pattern matching code to not store the required final
/ before the *, and then to require each side to be a valid ref (or
empty). In particular, any refspec that looks like it should be a
pattern but doesn't quite meet the requirements will be found to be
invalid as a fallback non-pattern.
This was cherry picked from commit ef00d15 (Tighten refspec processing,
2008-03-17), and two fix-up commits 46220ca (remote.c: Fix overtight
refspec validation, 2008-03-20) and 7d19da4 (refspec: allow colon-less
wildcard "refs/category/*", 2008-03-25) squashed in.
Signed-off-by: Daniel Barkalow <barkalow@iabervon.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-fetch.c | diff | blob | history | |
builtin-send-pack.c | diff | blob | history | |
remote.c | diff | blob | history | |
remote.h | diff | blob | history | |
t/t5511-refspec.sh | [new file with mode: 0755] | blob |