mirror of
https://github.com/RGBCube/serenity
synced 2025-07-26 08:37:45 +00:00
Lagom/Fuzzers: Add fuzzer for the TGALoader code
This commit is contained in:
parent
71f275b5ad
commit
b2626d3bc1
3 changed files with 22 additions and 0 deletions
16
Meta/Lagom/Fuzzers/FuzzTGALoader.cpp
Normal file
16
Meta/Lagom/Fuzzers/FuzzTGALoader.cpp
Normal file
|
@ -0,0 +1,16 @@
|
|||
/*
|
||||
* Copyright (c) 2022, Liav A. <liavalb@hotmail.co.il>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#include <LibGfx/TGALoader.h>
|
||||
#include <stddef.h>
|
||||
#include <stdint.h>
|
||||
|
||||
extern "C" int LLVMFuzzerTestOneInput(uint8_t const* data, size_t size)
|
||||
{
|
||||
Gfx::TGAImageDecoderPlugin decoder(data, size);
|
||||
(void)decoder.frame(0);
|
||||
return 0;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue