Skip to content

Commit

Permalink
🚑 fix for #516 and #518
Browse files Browse the repository at this point in the history
We should compare the binary serializations rather than the JSON values
themselves. This fix was already done for CBOR and apparently forgotten
for MessagePack.
  • Loading branch information
nlohmann committed Mar 17, 2017
1 parent 2d474b5 commit f547679
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions test/src/fuzzer-parse_msgpack.cpp
Expand Up @@ -41,8 +41,8 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size)
// parse serialization
json j2 = json::from_msgpack(vec2);

// deserializations must match
assert(j1 == j2);
// serializations must match
assert(json::to_msgpack(j2) == vec2);
}
catch (const json::parse_error&)
{
Expand Down

0 comments on commit f547679

Please sign in to comment.