changeset 12225:88ba739dc4d5 stable

i18n: merge with stable
author Wagner Bruna <wbruna@softwareexpress.com.br>
date Tue, 24 Aug 2010 10:58:12 -0300
parents b20211b307b3 (diff) ea566c2632b4 (current diff)
children 3e0b0af0591b
files
diffstat 4 files changed, 9 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/filemerge.py	Sat Aug 21 11:21:49 2010 +0200
+++ b/mercurial/filemerge.py	Tue Aug 24 10:58:12 2010 -0300
@@ -138,9 +138,6 @@
     if not fco.cmp(fcd.data()): # files identical?
         return None
 
-    if fca == fco: # backwards, use working dir parent as ancestor
-        fca = fcd.parents()[0]
-
     ui = repo.ui
     fd = fcd.path()
     binary = isbin(fcd) or isbin(fco) or isbin(fca)
--- a/mercurial/hbisect.py	Sat Aug 21 11:21:49 2010 +0200
+++ b/mercurial/hbisect.py	Tue Aug 24 10:58:12 2010 -0300
@@ -61,6 +61,8 @@
         badrev, ancestors = buildancestors(state['good'], state['bad'])
     bad = changelog.node(badrev)
     if not ancestors: # now we're confused
+        if len(state['bad']) == 1 and len(state['good']) == 1:
+            raise util.Abort(_("starting revisions are not directly related"))
         raise util.Abort(_("Inconsistent state, %s:%s is good and bad")
                          % (badrev, short(bad)))
 
--- a/mercurial/merge.py	Sat Aug 21 11:21:49 2010 +0200
+++ b/mercurial/merge.py	Tue Aug 24 10:58:12 2010 -0300
@@ -270,7 +270,12 @@
             repo.ui.debug("preserving %s for resolve of %s\n" % (f, fd))
             fcl = wctx[f]
             fco = mctx[f2]
-            fca = fcl.ancestor(fco, actx) or repo.filectx(f, fileid=nullrev)
+            if mctx == actx: # backwards, use working dir parent as ancestor
+                fca = fcl.parents()[0]
+            else:
+                fca = fcl.ancestor(fco, actx)
+            if not fca:
+                fca = repo.filectx(f, fileid=nullrev)
             ms.add(fcl, fco, fca, fd, flags)
             if f != fd and move:
                 moves.append(f)
--- a/tests/test-bisect.out	Sat Aug 21 11:21:49 2010 +0200
+++ b/tests/test-bisect.out	Tue Aug 24 10:58:12 2010 -0300
@@ -237,7 +237,7 @@
 date:        Thu Jan 01 00:00:01 1970 +0000
 summary:     msg 1
 
-abort: Inconsistent state, 31:58c80a7c8a40 is good and bad
+abort: starting revisions are not directly related
 error
 Testing changeset 15:e7fa0811edb0 (32 changesets remaining, ~5 tests)
 5cd978ea5149