Skip to content

Commit

Permalink
extend temp str buffer size
Browse files Browse the repository at this point in the history
  • Loading branch information
qinzuoyan committed Jul 16, 2015
1 parent 84c3577 commit 487bba4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions util/db_info_dumper.cc
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ void DumpDBFileSummary(const DBOptions& options, const std::string& dbname) {
break;
case kLogFile:
env->GetFileSize(dbname + "/" + file, &file_size);
char str[8];
char str[16];
snprintf(str, sizeof(str), "%" PRIu64, file_size);
wal_info.append(file).append(" size: ").
append(str).append(" ; ");
Expand Down Expand Up @@ -115,7 +115,7 @@ void DumpDBFileSummary(const DBOptions& options, const std::string& dbname) {
if (ParseFileName(file, &number, &type)) {
if (type == kLogFile) {
env->GetFileSize(options.wal_dir + "/" + file, &file_size);
char str[8];
char str[16];
snprintf(str, sizeof(str), "%" PRIu64, file_size);
wal_info.append(file).append(" size: ").
append(str).append(" ; ");
Expand Down

0 comments on commit 487bba4

Please sign in to comment.