From f547679de5ca07a5c7aef508c1b31dce6cff2173 Mon Sep 17 00:00:00 2001 From: Niels Lohmann Date: Fri, 17 Mar 2017 22:18:05 +0100 Subject: [PATCH] :ambulance: fix for #516 and #518 We should compare the binary serializations rather than the JSON values themselves. This fix was already done for CBOR and apparently forgotten for MessagePack. --- test/src/fuzzer-parse_msgpack.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/src/fuzzer-parse_msgpack.cpp b/test/src/fuzzer-parse_msgpack.cpp index 420283a4..667a68d6 100644 --- a/test/src/fuzzer-parse_msgpack.cpp +++ b/test/src/fuzzer-parse_msgpack.cpp @@ -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&) {