From 175d5d6a9e7c6138e678429618759504f7f7e6e4 Mon Sep 17 00:00:00 2001 From: Maysam Yabandeh Date: Tue, 14 Nov 2017 08:42:14 -0800 Subject: [PATCH] Properly destruct rebuilding_trx_ Summary: When testing rebuilding_trx_ in MemTableInserter might still be set before the tests finishes which would cause ASAN alarms for leaks. This patch deletes the pointers in MemTableInserter destructor. Closes https://github.com/facebook/rocksdb/pull/3162 Differential Revision: D6317113 Pulled By: maysamyabandeh fbshipit-source-id: a68be70709a4fff7ac2b768660119311968f9c21 --- db/write_batch.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/db/write_batch.cc b/db/write_batch.cc index 9dee47c5f..d70014f0a 100644 --- a/db/write_batch.cc +++ b/db/write_batch.cc @@ -980,6 +980,7 @@ class MemTableInserter : public WriteBatch::Handler { reinterpret_cast (&mem_post_info_map_)->~MemPostInfoMap(); } + delete rebuilding_trx_; } MemTableInserter(const MemTableInserter&) = delete;