From: Michal 'vorner' Vaner Date: Mon, 29 Oct 2012 12:23:51 +0000 (+0100) Subject: [2209] Remove unused memory segment X-Git-Tag: trac2487_base~21^2~8^2~1 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=b2964261a72d6eff164cafe4b24fd5bfce0fa469;p=thirdparty%2Fkea.git [2209] Remove unused memory segment --- diff --git a/src/lib/datasrc/client_list.cc b/src/lib/datasrc/client_list.cc index d28b822bfc..e7fb63b9dc 100644 --- a/src/lib/datasrc/client_list.cc +++ b/src/lib/datasrc/client_list.cc @@ -72,21 +72,10 @@ ConfigurableClientList::DataSourceInfo::getCacheClient() const { ConfigurableClientList::ConfigurableClientList(const RRClass& rrclass) : rrclass_(rrclass), - mem_sgmt_(new util::MemorySegmentLocal), configuration_(new isc::data::ListElement), allow_cache_(false) {} -ConfigurableClientList::~ConfigurableClientList() { - // Explicitly clear the contained data source clients, and check memory - // leak. assert() (with abort on failure) may be too harsh, but - // it's probably better to find more leaks initially. Once it's stabilized - // we should probably revisit it. - - data_sources_.clear(); - assert(mem_sgmt_->allMemoryDeallocated()); -} - void ConfigurableClientList::configure(const ConstElementPtr& config, bool allow_cache) diff --git a/src/lib/datasrc/client_list.h b/src/lib/datasrc/client_list.h index 5f792378bc..c78b21e2c9 100644 --- a/src/lib/datasrc/client_list.h +++ b/src/lib/datasrc/client_list.h @@ -222,9 +222,6 @@ public: /// \param rrclass For which class the list should work. ConfigurableClientList(const isc::dns::RRClass& rrclass); - /// \brief Destructor - virtual ~ConfigurableClientList(); - /// \brief Exception thrown when there's an error in configuration. class ConfigurationError : public Exception { public: @@ -408,12 +405,6 @@ private: bool want_exact_match, bool want_finder) const; const isc::dns::RRClass rrclass_; - /// \brief Memory segment for in-memory cache. - /// - /// Note that this must be placed before data_sources_ so it won't be - /// destroyed before the built objects in the destructor. - boost::scoped_ptr mem_sgmt_; - /// \brief Currently active configuration. isc::data::ConstElementPtr configuration_;