forked from qt-creator/qt-creator
ClangCodeModel: fix memory leak
amends 45317da25a
Change-Id: I27d3332f1a99676c174f18ff06d0cf0cea396b70
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
@@ -152,7 +152,11 @@ IAssistProcessor *ClangdCompletionAssistProvider::createProcessor(
|
|||||||
if (contextAnalyzer.completionAction()
|
if (contextAnalyzer.completionAction()
|
||||||
!= ClangCompletionContextAnalyzer::CompleteIncludePath) {
|
!= ClangCompletionContextAnalyzer::CompleteIncludePath) {
|
||||||
class NoOpProcessor : public IAssistProcessor {
|
class NoOpProcessor : public IAssistProcessor {
|
||||||
IAssistProposal *perform(const AssistInterface *) override { return nullptr; }
|
IAssistProposal *perform(const AssistInterface *interface) override
|
||||||
|
{
|
||||||
|
delete interface;
|
||||||
|
return nullptr;
|
||||||
|
}
|
||||||
};
|
};
|
||||||
return new NoOpProcessor;
|
return new NoOpProcessor;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user