* Updated copyright headers
* Revert "Fixed linker warnings in docs snippets on Windows (#15119)"
This reverts commit 372699ec49.
24 lines
681 B
C
24 lines
681 B
C
// Copyright (C) 2018-2023 Intel Corporation
|
|
// SPDX-License-Identifier: Apache-2.0
|
|
//
|
|
|
|
/*!
|
|
\file
|
|
\brief Replacement of libFuzzer main entrypoint for fuzz tests.
|
|
|
|
Include this file into code so that Microsoft linker can resolve
|
|
main entrypoint from static library.
|
|
Microsoft linker only resolve libary functions which are referenced,
|
|
`main` is not.
|
|
*/
|
|
#ifndef TESTS_FUZZ_TESTHELPER_MAIN_H_
|
|
#define TESTS_FUZZ_TESTHELPER_MAIN_H_
|
|
|
|
#if !defined(WITH_LIBFUZZER)
|
|
extern "C" int main(int argc, char* argv[]);
|
|
// make a reference to main so linker resolve it from static library
|
|
void* main_ptr_ = (void*)main;
|
|
#endif // !defined(WITH_LIBFUZZER)
|
|
|
|
#endif // TESTS_FUZZ_TESTHELPER_MAIN_H_
|