# HG changeset patch # User Manuel Jacob # Date 2024-08-05 19:21:32 # Node ID 6d7fdf90aa963e1262e37afed3273a121909d7f2 # Parent ecc3a893979d65a0a541238e68e2fec94f3223d3 cffi: call bytes() instead of str() on CFFI buffer instances diff --git a/mercurial/cffi/bdiff.py b/mercurial/cffi/bdiff.py --- a/mercurial/cffi/bdiff.py +++ b/mercurial/cffi/bdiff.py @@ -76,7 +76,7 @@ def bdiff(sa: bytes, sb: bytes) -> bytes lgt, ) ) - rl.append(str(ffi.buffer((b[0] + lb).l, lgt))) + rl.append(bytes(ffi.buffer((b[0] + lb).l, lgt))) la = h.a2 lb = h.b2 h = h.next