提交 90415cfe 编写于 作者: Y Yueh-Hsuan Chiang

Fixed a compile warning in linux32 environment.

Summary:
Fixed the following compile warning in linux32 environment.

    ==> linux32: util/sst_dump_tool.cc: In member function ‘int
                 rocksdb::SstFileReader::ShowAllCompressionSizes(size_t)’:
    ==> linux32: util/sst_dump_tool.cc:167:50: warning: format ‘%lu’ expects
                 argument of type ‘long unsigned int’, but argument 3 has type
                 ‘size_t {aka unsigned int}’ [-Wformat=]
    ==> linux32:    fprintf(stdout, "Block Size: %lu\n", block_size);

Test Plan: make sst_dump

Reviewers: anthony, IslamAbdelRahman, sdong, igor

Reviewed By: igor

Subscribers: dhruba, leveldb

Differential Revision: https://reviews.facebook.net/D45885
上级 9d6503f8
......@@ -12,6 +12,7 @@
#endif
#include <inttypes.h>
#include "port/port.h"
namespace rocksdb {
......@@ -166,7 +167,7 @@ int SstFileReader::ShowAllCompressionSizes(size_t block_size) {
compress_type.insert(std::make_pair(CompressionType::kZSTDNotFinalCompression,
"kZSTDNotFinalCompression"));
fprintf(stdout, "Block Size: %lu\n", block_size);
fprintf(stdout, "Block Size: %" ROCKSDB_PRIszt "\n", block_size);
for (CompressionType i = CompressionType::kNoCompression;
i <= CompressionType::kZSTDNotFinalCompression;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册