We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 82665fd commit 2f1fe32Copy full SHA for 2f1fe32
ext/dom/html_document.c
@@ -511,7 +511,8 @@ static bool dom_decode_encode_fast_path(
511
const lxb_char_t *last_output = buf_ref;
512
while (buf_ref != buf_end) {
513
const lxb_char_t *buf_ref_backup = buf_ref;
514
- lxb_codepoint_t codepoint = decoding_encoding_ctx->decode_data->decode_single(&decoding_encoding_ctx->decode, &buf_ref, buf_end);
+ /* Fast path converts non-validated UTF-8 -> validated UTF-8 */
515
+ lxb_codepoint_t codepoint = lxb_encoding_decode_utf_8_single(&decoding_encoding_ctx->decode, &buf_ref, buf_end);
516
if (UNEXPECTED(codepoint > LXB_ENCODING_MAX_CODEPOINT)) {
517
size_t skip = buf_ref - buf_ref_backup; /* Skip invalid data, it's replaced by the UTF-8 replacement bytes */
518
if (!dom_process_parse_chunk(
0 commit comments