Files
tubestation/tools/fuzzing/libfuzzer/harness/LibFuzzerRunner.h
Mike Hommey e521d08008 Bug 1330533 - Use FuzzerDriver directly instead of wrapping it in a libfuzzer_main function. r=decoder
Going further from the previous changes, all libfuzzer_main really does
is call the init function, and then proceed to call the fuzzer driver
with the testing function.

So instead of calling that function for it to do all that, the
LibFuzzerRunner can just call the init function itself, and then
call the fuzzer driver with the testing function.
2017-01-12 14:44:18 +09:00

22 lines
565 B
C++

/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*-
* * This Source Code Form is subject to the terms of the Mozilla Public
* * License, v. 2.0. If a copy of the MPL was not distributed with this
* * file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "LibFuzzerRegistry.h"
namespace mozilla {
class LibFuzzerRunner {
public:
int Run(int* argc, char*** argv);
void setParams(LibFuzzerDriver aDriver);
private:
LibFuzzerDriver mFuzzerDriver;
};
extern LibFuzzerRunner* libFuzzerRunner;
} // namespace mozilla