mirror of
https://gitlab.kitware.com/cmake/cmake.git
synced 2026-10-02 04:02:23 +03:00
cmTarget: Fix memory leak when SOURCES property is cleared
This commit is contained in:
1 parent
cf74fc24d4
commit
407ff47eca
1 file changed
+1
@@ -1671,6 +1671,7 @@ void cmTarget::SetProperty(const std::string& prop, const char* value)
|
||||
this->Internal->SourceFilesMap.clear();
|
||||
cmListFileBacktrace lfbt = this->Makefile->GetBacktrace();
|
||||
cmGeneratorExpression ge(lfbt);
|
||||
cmDeleteAll(this->Internal->SourceEntries);
|
||||
this->Internal->SourceEntries.clear();
|
||||
cmsys::auto_ptr<cmCompiledGeneratorExpression> cge = ge.Parse(value);
|
||||
this->Internal->SourceEntries.push_back(
|
||||
|
||||
Reference in new issue
Block a user