Compare prefix to byte strings

This commit is contained in:
Christoph Gohlke 2013-03-13 23:28:30 -07:00
parent b9b6972097
commit 64c25bcf89

View File

@ -4,7 +4,7 @@ from io import BytesIO
import _webp
def _accept(prefix):
return prefix[:4] == "RIFF" and prefix[8:16] == "WEBPVP8 "
return prefix[:4] == b"RIFF" and prefix[8:16] == b"WEBPVP8 "
class WebPImageFile(ImageFile.ImageFile):