Unverified Commit fe51d9c3 authored by Mark Harris's avatar Mark Harris Committed by Jean-Marc Valin
Browse files

Relax JPEG check to allow EXIF metadata

Signed-off-by: Jean-Marc Valin's avatarJean-Marc Valin <jmvalin@jmvalin.ca>
parent bdf3369e
......@@ -106,8 +106,7 @@ static int oi_strncasecmp(const char *a, const char *b, int n){
static int is_jpeg(const unsigned char *buf, size_t length){
return length>=11&&memcmp(buf,"\xFF\xD8\xFF\xE0",4)==0
return length>=3&&memcmp(buf,"\xFF\xD8\xFF",3)==0;
static int is_png(const unsigned char *buf, size_t length){
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment