diff --git a/mutagen/id3.py b/mutagen/id3.py
index <HASH>..<HASH> 100644
--- a/mutagen/id3.py
+++ b/mutagen/id3.py
@@ -254,7 +254,8 @@ class ID3(DictProxy, mutagen.Metadata):
 
         if self.f_extended:
             extsize = self.__fullread(4)
-            if (extsize.decode('ascii') if PY3 else extsize) in Frames:
+            frame_id = extsize.decode("ascii", "replace") if PY3 else extsize
+            if frame_id in Frames:
                 # Some tagger sets the extended header flag but
                 # doesn't write an extended header; in this case, the
                 # ID3 data follows immediately. Since no extended
don't raise decode error when checking for potential frame id