--- a/mercurial/exchange.py Tue Feb 25 20:30:08 2014 +0100
+++ b/mercurial/exchange.py Tue Apr 01 17:21:52 2014 -0700
@@ -401,6 +401,8 @@
self.rheads = None
# list of missing changeset to fetch remotly
self.fetch = None
+ # result of changegroup pulling (used as returng code by pull)
+ self.cgresult = None
@util.propertycache
def pulledsubset(self):
@@ -455,9 +457,9 @@
pullop.common, pullop.fetch, pullop.rheads = tmp
if not pullop.fetch:
pullop.repo.ui.status(_("no changes found\n"))
- result = 0
+ pullop.cgresult = 0
else:
- result = _pullchangeset(pullop)
+ pullop.cgresult = _pullchangeset(pullop)
_pullphase(pullop)
_pullobsolete(pullop)
@@ -466,7 +468,7 @@
pullop.releasetransaction()
lock.release()
- return result
+ return pullop.cgresult
def _pullchangeset(pullop):
"""pull changeset from unbundle into the local repo"""