summaryrefslogtreecommitdiff
path: root/branch.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2013-10-23 13:32:50 -0700
committerJunio C Hamano <gitster@pobox.com>2013-10-23 13:32:50 -0700
commit74051fa805b2b4aa6a0c2e6d4663dc8969e80967 (patch)
tree9cfef445e4c0d2eed38d7f739157a848921ea697 /branch.c
parent6ba0d9551a2963a6fed83b90b55a373d79ef46d0 (diff)
parentb0f49ff13033621af06af742e3615fe905833562 (diff)
downloadgit-74051fa805b2b4aa6a0c2e6d4663dc8969e80967.tar.gz
Merge branch 'jh/checkout-auto-tracking' into maint
"git branch --track" had a minor regression in v1.8.3.2 and later that made it impossible to base your local work on anything but a local branch of the upstream repository you are tracking from. * jh/checkout-auto-tracking: t3200: fix failure on case-insensitive filesystems branch.c: Relax unnecessary requirement on upstream's remote ref name t3200: Add test demonstrating minor regression in 41c21f2 Refer to branch.<name>.remote/merge when documenting --track t3200: Minor fix when preparing for tracking failure t2024: Fix &&-chaining and a couple of typos
Diffstat (limited to 'branch.c')
-rw-r--r--branch.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/branch.c b/branch.c
index c5c6984cb5..2d15c19e3e 100644
--- a/branch.c
+++ b/branch.c
@@ -203,8 +203,7 @@ static int check_tracking_branch(struct remote *remote, void *cb_data)
struct refspec query;
memset(&query, 0, sizeof(struct refspec));
query.dst = tracking_branch;
- return !(remote_find_tracking(remote, &query) ||
- prefixcmp(query.src, "refs/heads/"));
+ return !remote_find_tracking(remote, &query);
}
static int validate_remote_tracking_branch(char *ref)