summaryrefslogtreecommitdiff
path: root/column.h
diff options
context:
space:
mode:
authorJohannes Schindelin <johannes.schindelin@gmx.de>2014-12-23 13:25:05 (GMT)
committerJunio C Hamano <gitster@pobox.com>2014-12-23 20:42:36 (GMT)
commitfb86e32dcc9ed07ee2f1df6aafbf34d469007b1f (patch)
tree7f881178376fdd55de4245c1c1ada520cda310fb /column.h
parentbbcefffcea9789e4a1a2023a1c778e2c07db77a7 (diff)
downloadgit-fb86e32dcc9ed07ee2f1df6aafbf34d469007b1f.zip
git-fb86e32dcc9ed07ee2f1df6aafbf34d469007b1f.tar.gz
git-fb86e32dcc9ed07ee2f1df6aafbf34d469007b1f.tar.bz2
git remote: allow adding remotes agreeing with url.<...>.insteadOf
When adding a remote, we make sure that the remote does not exist already. However, this test was not quite correct: when the url.<...>.insteadOf config variable was set to the remote name to be added, the code would assume that the remote exists already. Let's allow adding remotes when there is a url.<...>.insteadOf setting when both the name and the URL agree with the remote to be added. It might seem like a mistake to compare against remote->url[0] without verifying that remote->url_nr >=1, but at this point a missing URL has been filled by the name already, therefore url_nr cannot be zero. Noticed by Anastas Dancha. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'column.h')
0 files changed, 0 insertions, 0 deletions