# HG changeset patch
# User Matt Harbison <matt_harbison@yahoo.com>
# Date 2021-06-12 04:51:34
# Node ID 5fbac82a8780732e223135a01f79f7770f4897f2
# Parent  5e44936b82bee32c1285eb04439cdf9a50a6714d

revlog: byteify a few error strings

Differential Revision: https://phab.mercurial-scm.org/D10875

diff --git a/mercurial/revlog.py b/mercurial/revlog.py
--- a/mercurial/revlog.py
+++ b/mercurial/revlog.py
@@ -1760,7 +1760,7 @@ class revlog(object):
         elif compression_mode == COMP_MODE_INLINE:
             return self.decompress(data)
         else:
-            msg = 'unknown compression mode %d'
+            msg = b'unknown compression mode %d'
             msg %= compression_mode
             raise error.RevlogError(msg)
 
@@ -1826,7 +1826,7 @@ class revlog(object):
                 elif comp_mode == COMP_MODE_DEFAULT:
                     ladd(def_decomp(c))
                 else:
-                    msg = 'unknown compression mode %d'
+                    msg = b'unknown compression mode %d'
                     msg %= comp_mode
                     raise error.RevlogError(msg)
 
@@ -2054,7 +2054,7 @@ class revlog(object):
         elif comp == COMP_MODE_INLINE:
             segment = self.decompress(comp_segment)
         else:
-            msg = 'unknown compression mode %d'
+            msg = b'unknown compression mode %d'
             msg %= comp
             raise error.RevlogError(msg)