Unverified Commit f6dc570f authored by Wallace's avatar Wallace Committed by GitHub

fix warn (#147)

Signed-off-by: 's avatarLittle-Wallace <bupt2013211450@gmail.com>

Fix warn when titan is compiled with gcc 5.5.0
```
/home/pingcap/.cargo/git/checkouts/rust-rocksdb-e0eeb217423298aa/0e1a085/librocksdb_sys/libtitan_sys/titan/src/db_impl_gc.cc: In member function ‘rocksdb::Status rocksdb::titandb::TitanDBImpl::BackgroundGC(rocksdb::LogBuffer*, uint32_t)’:
/home/pingcap/.cargo/git/checkouts/rust-rocksdb-e0eeb217423298aa/0e1a085/librocksdb_sys/libtitan_sys/titan/src/db_impl_gc.cc:205:55: error: ‘gc_merge_rewrite’ may be used uninitialized in this function [-Werror=maybe-uninitialized]
                           &shuting_down_, stats_.get());
```
parent 3fcbc2b3
...@@ -164,7 +164,7 @@ Status TitanDBImpl::BackgroundGC(LogBuffer* log_buffer, ...@@ -164,7 +164,7 @@ Status TitanDBImpl::BackgroundGC(LogBuffer* log_buffer,
StopWatch gc_sw(env_, stats_.get(), BLOB_DB_GC_MICROS); StopWatch gc_sw(env_, stats_.get(), BLOB_DB_GC_MICROS);
std::unique_ptr<BlobGC> blob_gc; std::unique_ptr<BlobGC> blob_gc;
bool gc_merge_rewrite; bool gc_merge_rewrite = false;
std::unique_ptr<ColumnFamilyHandle> cfh; std::unique_ptr<ColumnFamilyHandle> cfh;
Status s; Status s;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment