You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It gives "Invalid JPEG metadata: Invalid segment size." error on Webkit Mac App. It is in function parseMetaData(file, callback, options, data) line 137
It gives a strange file attached below on load. It's 4 bytes jpeg. and canvas.toBlob gives null blob.
There is no problem with Chrome and Safari with the same code.
Hi @ozgurozkan123, sorry for the late reply.
Unfortunately the file you provided is not accessible anymore.
Can you upload it somewhere more permanent so we can have a look?
@darkvovich
The Invalid JPEG metadata: Invalid segment size. error is logged if the length defined in a JPEG APPn segment exceeds the size of the maxMetaDataSize option or the size of the file.
It seems like the image blob generated from a Canvas for your picture contains a JPEG APP2 segment that is larger than what is defined as maxMetaDataSize for image head replacement (currently 256 bytes).
I'm not sure why the Canvas generated image contains a bigger sized meta data segment for your image (since canvas data does not retain JPEG meta data), but I'll release a fix that raises this to 1024 bytes.
Activity
blueimp commentedon Sep 25, 2021
Hi @ozgurozkan123, sorry for the late reply.
Unfortunately the file you provided is not accessible anymore.
Can you upload it somewhere more permanent so we can have a look?
darkvovich commentedon Oct 17, 2021
I have the same problem with all my images =(
Chrome on Windows

blueimp commentedon Oct 20, 2021
@darkvovich
The
Invalid JPEG metadata: Invalid segment size.error is logged if the length defined in a JPEG APPn segment exceeds the size of themaxMetaDataSizeoption or the size of the file.It seems like the image blob generated from a Canvas for your picture contains a JPEG APP2 segment that is larger than what is defined as
maxMetaDataSizefor image head replacement (currently256bytes).I'm not sure why the Canvas generated image contains a bigger sized meta data segment for your image (since canvas data does not retain JPEG meta data), but I'll release a fix that raises this to
1024bytes.Raise maxMetaDataSize for replaceHead function.
darkvovich commentedon Oct 20, 2021
Thx!