I have a git repository that is tracking several remote branches:
$ git branch -a
* master
remotes/git-svn
remotes/origin/master
remotes/trunk
<
You probably accidentally created a local ref called 'origin/master'
for instance, if you did this
git branch origin/master
It would lead to this problem. This one looks suspect "refs/origin/master". "refs/heads/master" is your local master, "refs/remotes/origin/master" is your remote branch reference, and "refs/origin/master" is probably a mistake that is screwing you up.
You just need to delete that reference (git update-ref -d ) and things will start working again.