couple of small changes

This commit is contained in:
silverweed 2025-01-28 10:47:32 +01:00
parent 5ef52054f7
commit ff5792d6a4

View file

@ -415,7 +415,7 @@ struct Sec_Hover_Fn {
return; return;
} }
// Sanity check // Sanity check
if (size > 1000000) { if (size > 100'000'000) {
fprintf(stderr, "Frame size read at 0x%" PRIX64 " looks bogus" fprintf(stderr, "Frame size read at 0x%" PRIX64 " looks bogus"
" (is it really %s? Don't think so...); setting it to 0 for good measure.\n", " (is it really %s? Don't think so...); setting it to 0 for good measure.\n",
cur_field_off, to_pretty_size(arena, size).c()); cur_field_off, to_pretty_size(arena, size).c());
@ -430,7 +430,7 @@ struct Sec_Hover_Fn {
} else { } else {
if (!n_items) { if (!n_items) {
// Since the caller didn't pass us a pointer to n_items, they think we're supposed // Since the caller didn't pass us a pointer to n_items, they think we're supposed
// to be parsing a record frame. But it turns out this is actually a frame list! // to be parsing a record frame. But it turns out this is actually a list frame!
// Something fishy is going on, so just bail out. // Something fishy is going on, so just bail out.
frame_type = Frame_INVALID; frame_type = Frame_INVALID;
} else { } else {