diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 03:50:45 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-06-12 03:50:45 +0000 |
commit | efeb864cb547a2cbf96dc0053a8bdb4d9190b364 (patch) | |
tree | c0b83368f18be983fcc763200c4c24d633244588 /src/resolve/fuzz-resource-record.c | |
parent | Releasing progress-linux version 255.5-1~progress7.99u1. (diff) | |
download | systemd-efeb864cb547a2cbf96dc0053a8bdb4d9190b364.tar.xz systemd-efeb864cb547a2cbf96dc0053a8bdb4d9190b364.zip |
Merging upstream version 256.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'src/resolve/fuzz-resource-record.c')
-rw-r--r-- | src/resolve/fuzz-resource-record.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/src/resolve/fuzz-resource-record.c b/src/resolve/fuzz-resource-record.c index 358a5c7..f792167 100644 --- a/src/resolve/fuzz-resource-record.c +++ b/src/resolve/fuzz-resource-record.c @@ -26,12 +26,10 @@ int LLVMFuzzerTestOneInput(const uint8_t *data, size_t size) { assert_se(f = memstream_init(&m)); (void) fprintf(f, "%s", strna(dns_resource_record_to_string(rr))); - if (dns_resource_record_to_json(rr, &v) < 0) - return 0; - - (void) json_variant_dump(v, JSON_FORMAT_PRETTY|JSON_FORMAT_COLOR|JSON_FORMAT_SOURCE, f, NULL); - (void) dns_resource_record_to_wire_format(rr, false); - (void) dns_resource_record_to_wire_format(rr, true); + assert_se(dns_resource_record_to_json(rr, &v) >= 0); + assert_se(json_variant_dump(v, JSON_FORMAT_PRETTY|JSON_FORMAT_COLOR|JSON_FORMAT_SOURCE, f, NULL) >= 0); + assert_se(dns_resource_record_to_wire_format(rr, false) >= 0); + assert_se(dns_resource_record_to_wire_format(rr, true) >= 0); return 0; } |