[jira] [Updated] (TEXT-44) NumericEntityUnescaper.translate throws an IllegalArgumentException if entityValue > MAX_CODE_POINT

2017-05-19 Thread Rob Tompkins (JIRA)

 [ 
https://issues.apache.org/jira/browse/TEXT-44?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Rob Tompkins updated TEXT-44:
-
Fix Version/s: (was: 1.1)
   1.x

> NumericEntityUnescaper.translate throws an IllegalArgumentException if 
> entityValue > MAX_CODE_POINT
> ---
>
> Key: TEXT-44
> URL: https://issues.apache.org/jira/browse/TEXT-44
> Project: Commons Text
>  Issue Type: Bug
>Reporter: Miquel
>Priority: Minor
> Fix For: 1.x
>
>
> We found that using the function StringEscapeUtils.unescapeHtml4 crashes if 
> the argument is "�" and throws an IllegalArgumentException.
> This happens because internally it calls the function 
> NumericEntityUnescaper.translate and doesn't check if the value is bigger 
> than 0x10 (MAX_CODE_POINT) that is a check inside Character.toChar.
> Maybe we need to check that the entity value is less than Char.MAX_CODE_POINT.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


[jira] [Updated] (TEXT-44) NumericEntityUnescaper.translate throws an IllegalArgumentException if entityValue > MAX_CODE_POINT

2016-12-30 Thread Rob Tompkins (JIRA)

 [ 
https://issues.apache.org/jira/browse/TEXT-44?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Rob Tompkins updated TEXT-44:
-
Fix Version/s: 1.1

> NumericEntityUnescaper.translate throws an IllegalArgumentException if 
> entityValue > MAX_CODE_POINT
> ---
>
> Key: TEXT-44
> URL: https://issues.apache.org/jira/browse/TEXT-44
> Project: Commons Text
>  Issue Type: Bug
>Reporter: Miquel
>Priority: Minor
> Fix For: 1.1
>
>
> We found that using the function StringEscapeUtils.unescapeHtml4 crashes if 
> the argument is "�" and throws an IllegalArgumentException.
> This happens because internally it calls the function 
> NumericEntityUnescaper.translate and doesn't check if the value is bigger 
> than 0x10 (MAX_CODE_POINT) that is a check inside Character.toChar.
> Maybe we need to check that the entity value is less than Char.MAX_CODE_POINT.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)