mirror of
https://github.com/RPCSX/llvm.git
synced 2024-12-11 21:57:55 +00:00
de20a5381a
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@302494 91177308-0d34-0410-b5e6-96231b3b80d8
14 lines
365 B
C++
14 lines
365 B
C++
// This file is distributed under the University of Illinois Open Source
|
|
// License. See LICENSE.TXT for details.
|
|
|
|
// Simple test for a fuzzer. Make sure we abort if Data is overwritten.
|
|
#include <cstdint>
|
|
#include <iostream>
|
|
|
|
extern "C" int LLVMFuzzerTestOneInput(const uint8_t *Data, size_t Size) {
|
|
if (Size)
|
|
*const_cast<uint8_t*>(Data) = 1;
|
|
return 0;
|
|
}
|
|
|