[ 
https://issues.apache.org/jira/browse/IMAGING-168?focusedWorklogId=286685&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-286685
 ]

ASF GitHub Bot logged work on IMAGING-168:
------------------------------------------

                Author: ASF GitHub Bot
            Created on: 01/Aug/19 12:40
            Start Date: 01/Aug/19 12:40
    Worklog Time Spent: 10m 
      Work Description: michael-o commented on pull request #18: IMAGING-168 
installing package with Swedish characters adds junk char…
URL: https://github.com/apache/commons-imaging/pull/18#discussion_r309674642
 
 

 ##########
 File path: 
src/main/java/org/apache/commons/imaging/formats/jpeg/iptc/IptcParser.java
 ##########
 @@ -438,8 +477,8 @@ public int compare(final IptcRecord e1, final IptcRecord 
e2) {
                 }
                 bos.write(element.iptcType.getType());
 
-                final byte[] recordData = element.value.getBytes("ISO-8859-1");
-                if (!new String(recordData, 
"ISO-8859-1").equals(element.value)) {
+                final byte[] recordData = 
element.value.getBytes(DEFAULT_ENCODING);
+                if (!new String(recordData, 
DEFAULT_ENCODING).equals(element.value)) {
                     throw new ImageWriteException(
                             "Invalid record value, not ISO-8859-1");
 
 Review comment:
   This should also use `DEFAULT_ENCODING
 
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Issue Time Tracking
-------------------

    Worklog Id:     (was: 286685)
    Time Spent: 1h  (was: 50m)

> IPTC parser should use CodedCharacterSet tag to determine encoding of the 
> IPTC tag values
> -----------------------------------------------------------------------------------------
>
>                 Key: IMAGING-168
>                 URL: https://issues.apache.org/jira/browse/IMAGING-168
>             Project: Commons Imaging
>          Issue Type: Bug
>          Components: Format: JPEG
>            Reporter: sudeep khemka
>            Priority: Major
>             Fix For: Review Patch
>
>         Attachments: codedCharacterSet.patch
>
>          Time Spent: 1h
>  Remaining Estimate: 0h
>
> The IPTC CodedCharacterSet tag can be used to specify the encoding of the 
> IPTC tag values. But the setting is currently ignored.



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)

Reply via email to