Free memory after use
Summary: Pull Request resolved: https://github.com/facebook/rocksdb/pull/4857 Differential Revision: D13602688 Pulled By: riversand963 fbshipit-source-id: 993419a6afb982a7a701ff71daebebb4b4a6b265
This commit is contained in:
parent
f3a99e8a4d
commit
ffc9f84649
@ -3802,6 +3802,14 @@ class AtomicFlushStressTest : public StressTest {
|
|||||||
&cf_handles, &checkpoint_db);
|
&cf_handles, &checkpoint_db);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (checkpoint_db != nullptr) {
|
||||||
|
for (auto cfh : cf_handles) {
|
||||||
|
delete cfh;
|
||||||
|
}
|
||||||
|
cf_handles.clear();
|
||||||
|
delete checkpoint_db;
|
||||||
|
checkpoint_db = nullptr;
|
||||||
|
}
|
||||||
DestroyDB(checkpoint_dir, Options());
|
DestroyDB(checkpoint_dir, Options());
|
||||||
if (!s.ok()) {
|
if (!s.ok()) {
|
||||||
fprintf(stderr, "A checkpoint operation failed with: %s\n",
|
fprintf(stderr, "A checkpoint operation failed with: %s\n",
|
||||||
|
Loading…
Reference in New Issue
Block a user