From 5f414da194dca59d367d3b95862418f0d4171e83 Mon Sep 17 00:00:00 2001 From: Dirk Farin Date: Sat, 16 Nov 2024 20:23:08 +0100 Subject: [PATCH] fix compilation of color-conversion-fuzzer --- fuzzing/color_conversion_fuzzer.cc | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/fuzzing/color_conversion_fuzzer.cc b/fuzzing/color_conversion_fuzzer.cc index af2e60fc2b..c80acfd879 100644 --- a/fuzzing/color_conversion_fuzzer.cc +++ b/fuzzing/color_conversion_fuzzer.cc @@ -256,16 +256,15 @@ extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) nullptr, output_bpp, options->color_conversion_options); - assert(out_image_result); - auto out_image = *out_image_result; - - heif_encoding_options_free(options); - - if (!out_image) { + if (out_image_result.error) { // Conversion is not supported. return 0; } + auto out_image = *out_image_result; + + heif_encoding_options_free(options); + assert(out_image->get_width() == width); assert(out_image->get_height() == height); assert(out_image->get_chroma_format() ==