subrepo: disallow all unknown git ref types stable
authorEric Eisner <ede@mit.edu>
Wed, 23 Feb 2011 10:17:44 -0500
branchstable
changeset 13465 fa88fabc1d66
parent 13464 da0ddd62b9d8
child 13466 f2295f7cd468
subrepo: disallow all unknown git ref types
mercurial/subrepo.py
--- a/mercurial/subrepo.py	Wed Feb 23 11:42:41 2011 +0100
+++ b/mercurial/subrepo.py	Wed Feb 23 10:17:44 2011 -0500
@@ -730,7 +730,8 @@
                                 '%(objectname) %(refname)'])
         for line in out.split('\n'):
             revision, ref = line.split(' ')
-            if ref.startswith('refs/tags/'):
+            if (not ref.startswith('refs/heads/') and
+                not ref.startswith('refs/remotes/')):
                 continue
             if ref.startswith('refs/remotes/') and ref.endswith('/HEAD'):
                 continue # ignore remote/HEAD redirects