mirror of
https://github.com/typesense/typesense.git
synced 2025-05-22 06:40:30 +08:00
Fix leak.
This commit is contained in:
parent
ae857b5dcd
commit
a5e7f82c82
@ -262,7 +262,6 @@ Option<bool> CollectionManager::load(const size_t collection_batch_size, const s
|
||||
collection_symlinks[parts[0]] = iter->value().ToString();
|
||||
iter->Next();
|
||||
}
|
||||
|
||||
delete iter;
|
||||
|
||||
// load presets
|
||||
@ -285,6 +284,7 @@ Option<bool> CollectionManager::load(const size_t collection_batch_size, const s
|
||||
|
||||
iter->Next();
|
||||
}
|
||||
delete iter;
|
||||
|
||||
//load stopwords
|
||||
std::string stopword_prefix_key = std::string(StopwordsManager::STOPWORD_PREFIX) + "_";
|
||||
@ -305,7 +305,7 @@ Option<bool> CollectionManager::load(const size_t collection_batch_size, const s
|
||||
|
||||
iter->Next();
|
||||
}
|
||||
|
||||
delete iter;
|
||||
|
||||
// restore query suggestions configs
|
||||
std::vector<std::string> analytics_config_jsons;
|
||||
@ -318,8 +318,6 @@ Option<bool> CollectionManager::load(const size_t collection_batch_size, const s
|
||||
AnalyticsManager::get_instance().create_rule(analytics_config, false, false);
|
||||
}
|
||||
|
||||
delete iter;
|
||||
|
||||
LOG(INFO) << "Loaded " << num_collections << " collection(s).";
|
||||
|
||||
loading_pool.shutdown();
|
||||
|
Loading…
x
Reference in New Issue
Block a user