[ https://issues.apache.org/jira/browse/CODEC-228?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15942341#comment-15942341 ]
Sebb commented on CODEC-228: ---------------------------- This is because the code uses new String(decoded_bytes, charset) to convert the result, and the behaviour of that ctor is unspecified for bytes that are invalid. There are probably other instances of this in the code base. > URLCodec.decode does not throw DecoderException with invalid UTF-8 > ------------------------------------------------------------------ > > Key: CODEC-228 > URL: https://issues.apache.org/jira/browse/CODEC-228 > Project: Commons Codec > Issue Type: Bug > Affects Versions: 1.10 > Reporter: Andrew Gaul > > I expect the following to throw {{DecoderException}}: > {code:java} > new URLCodec().decode("%AE%8A-", "UTF-8"); > {code} -- This message was sent by Atlassian JIRA (v6.3.15#6346)