Show More
@@ -702,14 +702,20 b' class basefilectx(object):' | |||||
702 | if fctx._customcmp: |
|
702 | if fctx._customcmp: | |
703 | return fctx.cmp(self) |
|
703 | return fctx.cmp(self) | |
704 |
|
704 | |||
705 |
if |
|
705 | if fctx._filenode is None: | |
706 |
|
|
706 | if self._repo._encodefilterpats: | |
707 | # if file data starts with '\1\n', empty metadata block is |
|
707 | # can't rely on size() because wdir content may be decoded | |
708 | # prepended, which adds 4 bytes to filelog.size(). |
|
708 | return self._filelog.cmp(self._filenode, fctx.data()) | |
709 |
|
|
709 | if self.size() - 4 == fctx.size(): | |
710 | or self.size() == fctx.size()): |
|
710 | # size() can match: | |
|
711 | # if file data starts with '\1\n', empty metadata block is | |||
|
712 | # prepended, which adds 4 bytes to filelog.size(). | |||
|
713 | return self._filelog.cmp(self._filenode, fctx.data()) | |||
|
714 | if self.size() == fctx.size(): | |||
|
715 | # size() matches: need to compare content | |||
711 | return self._filelog.cmp(self._filenode, fctx.data()) |
|
716 | return self._filelog.cmp(self._filenode, fctx.data()) | |
712 |
|
717 | |||
|
718 | # size() differs | |||
713 | return True |
|
719 | return True | |
714 |
|
720 | |||
715 | def _adjustlinkrev(self, srcrev, inclusive=False, stoprev=None): |
|
721 | def _adjustlinkrev(self, srcrev, inclusive=False, stoprev=None): |
General Comments 0
You need to be logged in to leave comments.
Login now