From 495ce6018a1f7fabc3675bbee1320a3b1c38e9f0 Mon Sep 17 00:00:00 2001 From: Yueh-Hsuan Chiang Date: Mon, 1 Jun 2015 14:58:40 -0700 Subject: [PATCH] Fixed compile warning in compact_files_example.cc Summary: Fixed compile warning in compact_files_example.cc Test Plan: compact_files_example Reviewers: sdong, igor Subscribers: dhruba, leveldb Differential Revision: https://reviews.facebook.net/D39309 --- examples/compact_files_example.cc | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/examples/compact_files_example.cc b/examples/compact_files_example.cc index 3e7638b7e..0ea58c8f7 100644 --- a/examples/compact_files_example.cc +++ b/examples/compact_files_example.cc @@ -14,7 +14,7 @@ using namespace rocksdb; std::string kDBPath = "/tmp/rocksdb_compact_files_example"; -class CompactionTask; +struct CompactionTask; // This is an example interface of external-compaction algorithm. // Compaction algorithm can be implemented outside the core-RocksDB @@ -35,19 +35,19 @@ class Compactor : public EventListener { // Example structure that describes a compaction task. struct CompactionTask { CompactionTask( - DB* db, Compactor* compactor, - const std::string& column_family_name, - const std::vector& input_file_names, - const int output_level, - const CompactionOptions& compact_options, - bool retry_on_fail) - : db(db), - compactor(compactor), - column_family_name(column_family_name), - input_file_names(input_file_names), - output_level(output_level), - compact_options(compact_options), - retry_on_fail(false) {} + DB* _db, Compactor* _compactor, + const std::string& _column_family_name, + const std::vector& _input_file_names, + const int _output_level, + const CompactionOptions& _compact_options, + bool _retry_on_fail) + : db(_db), + compactor(_compactor), + column_family_name(_column_family_name), + input_file_names(_input_file_names), + output_level(_output_level), + compact_options(_compact_options), + retry_on_fail(_retry_on_fail) {} DB* db; Compactor* compactor; const std::string& column_family_name;