# HG changeset patch # User Nicolas Dumazet # Date 2010-07-09 02:59:48 # Node ID 16fe98804fd80fb3424f3a6140a0aa92afbcac3e # Parent 0a044e5ff489e3018b3d783e3ac6290cec12dafa workingfilectx.cmp: invert boolean return value Apparently we mostly used filectx.cmp(workingfilectx.read()), so no error was ever triggered, but since all cmp() methods return True when content are different, that == should in fact be != diff --git a/mercurial/context.py b/mercurial/context.py --- a/mercurial/context.py +++ b/mercurial/context.py @@ -932,7 +932,7 @@ class workingfilectx(filectx): return (t, tz) def cmp(self, text): - return self._repo.wread(self._path) == text + return self._repo.wread(self._path) != text class memctx(object): """Use memctx to perform in-memory commits via localrepo.commitctx().