Fix use-after free in db_bench
Test Plan: valgrind db_bench Reviewers: igor, sdong Reviewed By: sdong Subscribers: dhruba Differential Revision: https://reviews.facebook.net/D52101
This commit is contained in:
parent
bf8ffc1d60
commit
a48382399d
@ -1633,9 +1633,8 @@ class Benchmark {
|
|||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
const char* compression =
|
auto compression = CompressionTypeToString(FLAGS_compression_type_e);
|
||||||
CompressionTypeToString(FLAGS_compression_type_e).c_str();
|
fprintf(stdout, "Compression: %s\n", compression.c_str());
|
||||||
fprintf(stdout, "Compression: %s\n", compression);
|
|
||||||
|
|
||||||
switch (FLAGS_rep_factory) {
|
switch (FLAGS_rep_factory) {
|
||||||
case kPrefixHash:
|
case kPrefixHash:
|
||||||
@ -1656,7 +1655,7 @@ class Benchmark {
|
|||||||
}
|
}
|
||||||
fprintf(stdout, "Perf Level: %d\n", FLAGS_perf_level);
|
fprintf(stdout, "Perf Level: %d\n", FLAGS_perf_level);
|
||||||
|
|
||||||
PrintWarnings(compression);
|
PrintWarnings(compression.c_str());
|
||||||
fprintf(stdout, "------------------------------------------------\n");
|
fprintf(stdout, "------------------------------------------------\n");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user