Fix CLANG build for db_bench

Summary: CLANG was broken for a recent change in db_ench. Fix it.

Test Plan: Build db_bench using CLANG.

Reviewers: rven, igor, yhchiang

Reviewed By: yhchiang

Subscribers: dhruba, leveldb

Differential Revision: https://reviews.facebook.net/D30801
This commit is contained in:
sdong 2014-12-30 18:33:35 -08:00
parent bf287b76e0
commit e9ca358157

View File

@ -398,12 +398,12 @@ enum rocksdb::CompressionType StringToCompressionType(const char* ctype) {
return rocksdb::kSnappyCompression; //default value
}
std::string ColumnFamilyName(int i) {
std::string ColumnFamilyName(size_t i) {
if (i == 0) {
return rocksdb::kDefaultColumnFamilyName;
} else {
char name[100];
snprintf(name, sizeof(name), "column_family_name_%06d", i);
snprintf(name, sizeof(name), "column_family_name_%06zu", i);
return std::string(name);
}
}