diff options
author | vng <viktor.govako@gmail.com> | 2012-05-22 20:44:37 +0400 |
---|---|---|
committer | Alex Zolotarev <alex@maps.me> | 2015-09-23 01:39:05 +0300 |
commit | 71dfe1b9e3ac1a161c2bc830ec5847f407eaa863 (patch) | |
tree | e2004747331f26f9c2d3efc6ae5d492363410c6b /indexer/feature.cpp | |
parent | cc5e4ad665e51f77e5fd8655ce6e70767a6093e9 (diff) |
Create feature::LoaderBase once and use it for all loading features - no "new-delete-shared_ptr" overhead for this.
Diffstat (limited to 'indexer/feature.cpp')
-rw-r--r-- | indexer/feature.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/indexer/feature.cpp b/indexer/feature.cpp index 3f0adf0e28..01e1210f3b 100644 --- a/indexer/feature.cpp +++ b/indexer/feature.cpp @@ -18,8 +18,8 @@ using namespace feature; void FeatureBase::Deserialize(feature::LoaderBase * pLoader, BufferT buffer) { - m_pLoader.reset(pLoader); - m_pLoader->Deserialize(buffer); + m_pLoader = pLoader; + m_pLoader->Init(buffer); m_LimitRect = m2::RectD::GetEmptyRect(); m_bTypesParsed = m_bCommonParsed = false; @@ -87,7 +87,7 @@ void FeatureType::Deserialize(feature::LoaderBase * pLoader, BufferT buffer) { base_type::Deserialize(pLoader, buffer); - m_pLoader->AssignFeature(this); + m_pLoader->InitFeature(this); m_bHeader2Parsed = m_bPointsParsed = m_bTrianglesParsed = false; |