From 4db46aa2e678cdd59ae27653fbefeb438512ec8a Mon Sep 17 00:00:00 2001 From: Siying Dong Date: Fri, 15 Feb 2019 16:10:37 -0800 Subject: [PATCH] Fix LITE Build (#4989) Summary: LITE mode has EventListener to be an empty class. However in db_bench, it is used. When "override" is added to the functions, the build breaks. Fix it by keeping the listener empty in LITE mode. Pull Request resolved: https://github.com/facebook/rocksdb/pull/4989 Differential Revision: D14108132 Pulled By: siying fbshipit-source-id: 80121aab35b1120e502b37b782301dd700692697 --- tools/db_bench_tool.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/tools/db_bench_tool.cc b/tools/db_bench_tool.cc index 1402c68d9..845c29bbb 100644 --- a/tools/db_bench_tool.cc +++ b/tools/db_bench_tool.cc @@ -2044,6 +2044,7 @@ class Benchmark { class ErrorHandlerListener : public EventListener { public: +#ifndef ROCKSDB_LITE ErrorHandlerListener() : mutex_(), cv_(&mutex_), @@ -2085,6 +2086,10 @@ class Benchmark { InstrumentedCondVar cv_; bool no_auto_recovery_; bool recovery_complete_; +#else // ROCKSDB_LITE + bool WaitForRecovery(uint64_t /*abs_time_us*/) { return true; } + void EnableAutoRecovery(bool /*enable*/) {} +#endif // ROCKSDB_LITE }; std::shared_ptr listener_;