summaryrefslogtreecommitdiff
path: root/chromium/testing/libfuzzer/fuzzers/empty_fuzzer.cc
blob: fb38e8023a01c9f3b6f93bba73dd68fcedbaa487 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
// Copyright 2015 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

// Empty fuzzer that doesn't do anything. Used as test and documentation.

#include <stddef.h>
#include <stdint.h>

// Fuzzer entry point.
extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size) {
  // Run your code on data.
  return 0;
}

// Environment is optional.
struct Environment {
  Environment() {
    // Initialize your environment.
  }
};

Environment* env = new Environment();