mercurial/commands.py
changeset 22617 1625770c2ce1
parent 22594 1257cc6c1a2f
child 22621 76a43e0db516
--- a/mercurial/commands.py	Thu Sep 25 02:21:59 2014 -0700
+++ b/mercurial/commands.py	Thu Sep 25 01:39:39 2014 -0700
@@ -5068,10 +5068,10 @@
                 return not result
     finally:
         del repo._subtoppath
-    result = repo.push(other, opts.get('force'), revs=revs,
-                       newbranch=opts.get('new_branch'))
-
-    result = not result
+    pushop = exchange.push(repo, other, opts.get('force'), revs=revs,
+                           newbranch=opts.get('new_branch'))
+
+    result = not pushop.cgresult
 
     if opts.get('bookmark'):
         bresult = bookmarks.pushtoremote(ui, repo, other, opts['bookmark'])