mirror of
https://github.com/facebook/sapling.git
synced 2024-10-07 23:38:50 +03:00
remotefilelog: the filelog data is bytes
Reviewed By: DurhamG Differential Revision: D19651372 fbshipit-source-id: 13bf86235b95ad84beb9fe45e7abc06baec67a47
This commit is contained in:
parent
4b2b0c6630
commit
6b328f5f7d
@ -111,7 +111,7 @@ def createrevlogtext(text, copyfrom=None, copyrev=None):
|
||||
traditional revlog
|
||||
"""
|
||||
meta = {}
|
||||
if copyfrom or text.startswith("\1\n"):
|
||||
if copyfrom or text.startswith(b"\1\n"):
|
||||
if copyfrom:
|
||||
meta["copy"] = copyfrom
|
||||
meta["copyrev"] = copyrev
|
||||
@ -128,8 +128,8 @@ def parsemeta(text, flags=0):
|
||||
meta = p.hgmeta()
|
||||
else:
|
||||
meta, size = filelog.parsemeta(text)
|
||||
if text.startswith("\1\n"):
|
||||
s = text.index("\1\n", 2)
|
||||
if text.startswith(b"\1\n"):
|
||||
s = text.index(b"\1\n", 2)
|
||||
text = text[s + 2 :]
|
||||
return meta or {}, text
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user