From 8cf1470a51ea276ca84825e7495d4ee24743540d Mon Sep 17 00:00:00 2001 From: Yash Tibrewal Date: Wed, 6 Dec 2017 09:47:54 -0800 Subject: Revert "Revert "All instances of exec_ctx being passed around in src/core removed"" --- test/core/util/one_corpus_entry_fuzzer.cc | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'test/core/util/one_corpus_entry_fuzzer.cc') diff --git a/test/core/util/one_corpus_entry_fuzzer.cc b/test/core/util/one_corpus_entry_fuzzer.cc index c0b67da1e2..c745eb5dc6 100644 --- a/test/core/util/one_corpus_entry_fuzzer.cc +++ b/test/core/util/one_corpus_entry_fuzzer.cc @@ -18,7 +18,10 @@ #include +#include + #include +#include "src/core/lib/iomgr/exec_ctx.h" #include "src/core/lib/iomgr/load_file.h" extern "C" int LLVMFuzzerTestOneInput(const uint8_t* data, size_t size); @@ -30,10 +33,15 @@ int main(int argc, char** argv) { grpc_slice buffer; squelch = false; leak_check = false; + /* TODO(yashkt) Calling grpc_init breaks tests. Fix the tests and replace + * grpc_core::ExecCtx::GlobalInit with grpc_init and GlobalShutdown with + * grpc_shutdown */ GPR_ASSERT( GRPC_LOG_IF_ERROR("load_file", grpc_load_file(argv[1], 0, &buffer))); LLVMFuzzerTestOneInput(GRPC_SLICE_START_PTR(buffer), GRPC_SLICE_LENGTH(buffer)); + grpc_core::ExecCtx::GlobalInit(); grpc_slice_unref(buffer); + grpc_core::ExecCtx::GlobalShutdown(); return 0; } -- cgit v1.2.3