You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Gary D. Gregory (Jira)" <ji...@apache.org> on 2022/11/09 10:50:00 UTC

[jira] [Commented] (IMAGING-338) Sanselan returns an empty set when retrieving the image metadata

    [ https://issues.apache.org/jira/browse/IMAGING-338?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17630987#comment-17630987 ] 

Gary D. Gregory commented on IMAGING-338:
-----------------------------------------

Hi [~somasaninikhil] 

Thank you for your ticket. 

Did you check if the code is still like this in git master?

Do you have an image to reproduce this? 

The best way to move forward is to create a ticket on GitHub, this will allow the patch to get automatically tested in a build. 

 

 

> Sanselan returns an empty set when retrieving the image metadata
> ----------------------------------------------------------------
>
>                 Key: IMAGING-338
>                 URL: https://issues.apache.org/jira/browse/IMAGING-338
>             Project: Commons Imaging
>          Issue Type: Bug
>    Affects Versions: 0.97
>            Reporter: Nikhil
>            Priority: Major
>
> We were using Sanselan to extract IPTC metadata. Recently there were images thats causing Sanselan to return an empty set when retrieving the metadata, despite the fact that there is clearly iptc metadata in the image.
>  
> The problem is seen in the following codebase
> IPTCParser.parseIPTCBlock(...), and is the second 'if' statement within the
> while loop. In particular, instead of the following:
> if (tagMarker != IPTC_RECORD_TAG_MARKER) {
>   if (verbose) {
>       System.out.println("Unexpected record tag marker in IPTC data.");
>   }
>   {*}return elements{*};
>  }
>  
> You should do the following to fix the issue:
>  
> if (tagMarker != IPTC_RECORD_TAG_MARKER) {
>   if (verbose) {
>       System.out.println("Unexpected record tag marker in IPTC data.");
>   }
>   *continue;*
> }
>  
> Credit @ [https://www.mail-archive.com/sanselan-dev@incubator.apache.org/msg00430.html] for the detailed notes



--
This message was sent by Atlassian Jira
(v8.20.10#820010)