Teach git_branch_remote_name() to work with orphaned heads