You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Dain Sundstrom (JIRA)" <ji...@apache.org> on 2008/01/23 20:33:34 UTC
[jira] Commented: (HARMONY-5414) java.util.Properties.load()
decodes invalid unicode sequences
[ https://issues.apache.org/jira/browse/HARMONY-5414?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12561788#action_12561788 ]
Dain Sundstrom commented on HARMONY-5414:
-----------------------------------------
The patch looks good. In my version I use the following exception messages for invalid unicode sequences:
// for sequences that are too short
"Invalid unicode sequence: expected format \\uxxxx, but got \\u" + new String(buf, 0, i)
// for sequences containing non-hex characters
"Illegal character " + nextChar + " in unicode sequence \\u" + new String(buf, 0, i + 1));
> java.util.Properties.load() decodes invalid unicode sequences
> -------------------------------------------------------------
>
> Key: HARMONY-5414
> URL: https://issues.apache.org/jira/browse/HARMONY-5414
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Reporter: Dain Sundstrom
> Assignee: Tim Ellison
> Attachments: harmony-5414.patch, PropertiesTest.java
>
>
> The load method on java.util.Properties will decode invalid unicode sequences like "\u123". After checking the spec regarding escaped unicode characters the sequence must contain exactly 4 hex digits.
> I found this while writing an extension to the Properties object based on the Harmony code base. The test attached to this issue also shows a few inconsistencies with the Sun vm that may be bugs also.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.