ladybird/Meta/Lagom/Fuzzers/FuzzGzipDecompression.cpp
2022-04-01 21:24:45 +01:00

14 lines
351 B
C++

/*
* Copyright (c) 2021, the SerenityOS developers.
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#include <LibCompress/Gzip.h>
#include <stdio.h>
extern "C" int LLVMFuzzerTestOneInput(uint8_t const* data, size_t size)
{
auto result = Compress::GzipDecompressor::decompress_all(ReadonlyBytes { data, size });
return result.has_value();
}