Skip to content

Commit

Permalink
Do not ignore WABT errors
Browse files Browse the repository at this point in the history
  • Loading branch information
chfast committed Oct 2, 2020
1 parent e93e024 commit 8c39c2a
Showing 1 changed file with 13 additions and 13 deletions.
26 changes: 13 additions & 13 deletions test/fuzzer/parser_fuzzer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -47,10 +47,10 @@ void handle_unexpected_errors() noexcept
__builtin_unreachable();
}

constexpr auto wabt_ignored_errors = {
"unable to read u32 leb128: version",
"invalid linking metadata version:",
};
//constexpr auto wabt_ignored_errors = {
// "unable to read u32 leb128: version",
// "invalid linking metadata version:",
//};

wabt::Errors wabt_errors;

Expand Down Expand Up @@ -135,15 +135,15 @@ int LLVMFuzzerTestOneInput(const uint8_t* data, size_t data_size) noexcept
bool has_errors = false;
for (const auto& err : wabt_errors)
{
bool ignored = false;

for (const auto& m : wabt_ignored_errors)
{
if (err.message.find(m) != std::string::npos)
ignored = true;
}
if (ignored)
continue;
// bool ignored = false;
//
// for (const auto& m : wabt_ignored_errors)
// {
// if (err.message.find(m) != std::string::npos)
// ignored = true;
// }
// if (ignored)
// continue;

std::cerr << " MISSED ERROR: " << err.message << "\n";
has_errors = true;
Expand Down

0 comments on commit 8c39c2a

Please sign in to comment.