mirror of https://github.com/facebook/rocksdb.git
Merge pull request #333 from nbougalis/cleanups
Don't return (or dereference) dangling pointer
This commit is contained in:
commit
c1273533bd
|
@ -28,6 +28,7 @@ ColumnFamilyData* FlushScheduler::GetNextColumnFamily() {
|
||||||
if (cfd->IsDropped()) {
|
if (cfd->IsDropped()) {
|
||||||
if (cfd->Unref()) {
|
if (cfd->Unref()) {
|
||||||
delete cfd;
|
delete cfd;
|
||||||
|
cfd = nullptr;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
break;
|
break;
|
||||||
|
|
Loading…
Reference in New Issue