Allow builtin-fetch to work on a detached HEAD
authorShawn O. Pearce <spearce@spearce.org>
Sun, 16 Sep 2007 06:31:26 +0000 (02:31 -0400)
committerJunio C Hamano <gitster@pobox.com>
Wed, 19 Sep 2007 10:22:31 +0000 (03:22 -0700)
commitb3abdd9d216c578383b66bb10b95edb3380640e7
treedd88b15779554faab706c0c5be033dec4f445b7b
parente5f4e214636f9c9bd36c2897634108d5ad5587a1
Allow builtin-fetch to work on a detached HEAD

If we are running fetch in a repository that has a detached HEAD
then there is no current_branch available.  In such a case any ref
that the fetch might update by definition cannot also be the current
branch so we should always bypass the "don't update HEAD" test.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin-fetch.c