[
https://issues.apache.org/jira/browse/IMAGING-187?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15547048#comment-15547048
]
Damjan Jovanovic commented on IMAGING-187:
------------------------------------------
The file contains a corrupt thumbnail. Reading the metadata attempts to read
the thumbnail by default, causing the exception. It's possible to skip reading
the thumbnail and avoid the exception:
Map<String,Object> params = new TreeMap<>();
params.put(ImagingConstants.PARAM_KEY_READ_THUMBNAILS, false);
JpegImageMetadata metadata = (JpegImageMetadata)
Imaging.getMetadata(new File("IMG_000-tf.jpg"), params);
> Could not read block - when JPG file is saved from TIFF
> -------------------------------------------------------
>
> Key: IMAGING-187
> URL: https://issues.apache.org/jira/browse/IMAGING-187
> Project: Commons Imaging
> Issue Type: Bug
> Affects Versions: 1.0
> Reporter: R.M.
> Attachments: IMG_000-tf.jpg
>
>
> I have got error
> java.io.IOException: Could not read block (block start: 399047, block length:
> 6240, data length: 9926).
> when I try to read EXIF or IPTC metadata (Imaging.getMetadata(file);)
> At first the file was saved in TIFF format. Then it was open and saved to
> final jpg format. This error I can see everytime, when I have any JPG saved
> from TIFF.
> I tried to use PaintShopPro and painting in windows.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)