imghdr.what failed to identify JPEG

Terry Reedy tjreedy at udel.edu
Sun Jun 8 14:59:55 EDT 2003


"Steven Taschuk" <staschuk at telusplanet.net> wrote in message
news:mailman.1055086335.1441.python-list at python.org...
> Quoth Arsenal:
>   [...]
> > Bytes [6:10] for my 52 jpg files are 'Exif'. So if imghdr.what
adds
> > this additonal check, all of my jpgs would be correctly
identified.
>
> That would be easy enough to implement, but I really have no idea
> whether it would be the Right Thing.
>
> The docs explicitly say that 'jpeg' is returned for JFIF JPEGs;
> not, that implies, for EXIF JPEGs.  I don't know what the
> differences between these standards are, nor whether or to what
> extent imghdr.what ought to be sensitive to the distinction.

This strikes me as something reasonable to submit an SF patch or bug
report for.

TJR






More information about the Python-list mailing list