diff --git a/glymur/jp2box.py b/glymur/jp2box.py index 81d8e6c..f05e9de 100644 --- a/glymur/jp2box.py +++ b/glymur/jp2box.py @@ -1854,7 +1854,7 @@ class XMLBox(Jp2kBox): except UnicodeDecodeError as ude: # Possibly bad string of bytes to begin with. # Try to search for -1: text = read_buffer[decl_start:].decode('utf-8') else: diff --git a/glymur/test/test_jp2k.py b/glymur/test/test_jp2k.py index 1ab5b29..4f06745 100644 --- a/glymur/test/test_jp2k.py +++ b/glymur/test/test_jp2k.py @@ -147,7 +147,6 @@ class TestBadButRecoverableXmlFile(unittest.TestCase): # Write out 48 good bytes constituting the XML payload. write_buffer = b'this is a test' - write_buffer = write_buffer.encode() tfile.write(write_buffer) # Get the rest of the input file.