Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 362742 - NotUtf8Exception should provide context on what failed
Summary: NotUtf8Exception should provide context on what failed
Status: RESOLVED FIXED
Alias: None
Product: Jetty
Classification: RT
Component: other (show other bugs)
Version: 7.5.4   Edit
Hardware: All All
: P3 normal (vote)
Target Milestone: 7.5.x   Edit
Assignee: Project Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-11-02 20:21 EDT by Joakim Erdfelt CLA
Modified: 2011-11-27 22:00 EST (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joakim Erdfelt CLA 2011-11-02 20:21:38 EDT
org.eclipse.jetty.util.Utf8Appendable$NotUtf8Exception: Not valid UTF8!

This is insufficient to detail what was invalid.
Ideas for what could be included...
+ Incomplete Sequence ___
+ Invalid byte at offset ___ in array [0-9A-F] ...
Comment 1 Greg Wilkins CLA 2011-11-27 22:00:02 EST
The exception now records the hex byte being added and the current state of the UTF-8 engine, but it does not give a detailed explanation of the reason.

The virtual method call isUtf8SequenceComplete was also removed from the appendByte algorithm as it was used 3 times and would greatly slow the algorithm.