Skip to content

Commit

Permalink
Merge branch '2.17'
Browse files Browse the repository at this point in the history
  • Loading branch information
cowtowncoder committed Feb 13, 2024
2 parents 3ea88fc + a70de23 commit 6224354
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -721,7 +721,7 @@ private final void _finishLongText(int len) throws IOException
break;
default:
// Is this good enough error message?
_reportInvalidChar(c);
_reportInvalidInitial(c);
}
// Need more room?
if (outPtr >= outEnd) {
Expand Down Expand Up @@ -770,14 +770,6 @@ private final int _decodeUTF8_4(int c) throws IOException
return ((c << 6) | (d & 0x3F)) - 0x10000;
}

protected void _reportInvalidChar(int c) throws JacksonException {
// Either invalid WS or illegal UTF-8 start char
if (c < ' ') {
_throwInvalidSpace(c);
}
_reportInvalidInitial(c);
}

private void _reportInvalidInitial(int mask) throws JacksonException {
_reportError("Invalid UTF-8 start byte 0x"+Integer.toHexString(mask));
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2102,7 +2102,7 @@ private final void _finishLongText(int len) throws JacksonException
break;
default:
// Is this good enough error message?
_reportInvalidChar(c);
_reportInvalidInitial(c);
}
// Need more room?
if (outPtr >= outEnd) {
Expand Down Expand Up @@ -2665,12 +2665,4 @@ private void _reportInvalidOther(int mask, int ptr) throws StreamReadException {
_inputPtr = ptr;
_reportInvalidOther(mask);
}

private void _reportInvalidChar(int c) throws StreamReadException {
// Either invalid WS or illegal UTF-8 start char
if (c < ' ') {
_throwInvalidSpace(c);
}
_reportInvalidInitial(c);
}
}

0 comments on commit 6224354

Please sign in to comment.