mercurial/hg.py
changeset 17922 7f5dab94e48c
parent 17900 47fb48060e36
child 17938 fd903f89e42b
--- a/mercurial/hg.py	Fri Nov 09 14:49:30 2012 -0800
+++ b/mercurial/hg.py	Wed Nov 07 16:21:39 2012 -0600
@@ -391,14 +391,15 @@
         destrepo = destpeer.local()
         if destrepo and srcpeer.capable("pushkey"):
             rb = srcpeer.listkeys('bookmarks')
+            marks = destrepo._bookmarks
             for k, n in rb.iteritems():
                 try:
                     m = destrepo.lookup(n)
-                    destrepo._bookmarks[k] = m
+                    marks[k] = m
                 except error.RepoLookupError:
                     pass
             if rb:
-                bookmarks.write(destrepo)
+                marks.write()
         elif srcrepo and destpeer.capable("pushkey"):
             for k, n in srcrepo._bookmarks.iteritems():
                 destpeer.pushkey('bookmarks', k, '', hex(n))