This is most likely a bug in libgit2. The ref I added above is renamed to refs/remotes/renamedd/master.