Fix std/cbor src.meta.ri for too much recursion

Updates https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=25145
This commit is contained in:
Nigel Tao committed 2020-08-24 00:39:54 +10:00
1 parent 75682548f5
commit 75e1efcc4a
2 files changed
+20

No files matched your search

+10
View File
@@ -17145,6 +17145,11 @@ wuffs_cbor__decoder__decode_tokens(
if (WUFFS_CBOR__TOKEN_LENGTHS[v_c_minor] == 0) {
goto label__goto_fail__break;
} else if (v_depth >= 1024) {
v_token_length = ((uint32_t)(WUFFS_CBOR__TOKEN_LENGTHS[v_c_minor]));
while ((v_token_length > 0) && (iop_a_src > io1_a_src)) {
(iop_a_src--, wuffs_base__make_empty_struct());
v_token_length -= 1;
}
status = wuffs_base__make_status(wuffs_cbor__error__unsupported_recursion_depth);
goto exit;
}
@@ -17181,6 +17186,11 @@ wuffs_cbor__decoder__decode_tokens(
if (WUFFS_CBOR__TOKEN_LENGTHS[v_c_minor] == 0) {
goto label__goto_fail__break;
} else if (v_depth >= 1024) {
v_token_length = ((uint32_t)(WUFFS_CBOR__TOKEN_LENGTHS[v_c_minor]));
while ((v_token_length > 0) && (iop_a_src > io1_a_src)) {
(iop_a_src--, wuffs_base__make_empty_struct());
v_token_length -= 1;
}
status = wuffs_base__make_status(wuffs_cbor__error__unsupported_recursion_depth);
goto exit;
}