[cfe-commits] r118371 - /cfe/trunk/lib/Sema/SemaLookup.cpp
Ted Kremenek
kremenek at apple.com
Sat Nov 6 23:11:33 PDT 2010
Author: kremenek
Date: Sun Nov 7 01:11:33 2010
New Revision: 118371
URL: http://llvm.org/viewvc/llvm-project?rev=118371&view=rev
Log:
Fix memory leak of IdentifierIterator object.
Modified:
cfe/trunk/lib/Sema/SemaLookup.cpp
Modified: cfe/trunk/lib/Sema/SemaLookup.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Sema/SemaLookup.cpp?rev=118371&r1=118370&r2=118371&view=diff
==============================================================================
--- cfe/trunk/lib/Sema/SemaLookup.cpp (original)
+++ cfe/trunk/lib/Sema/SemaLookup.cpp Sun Nov 7 01:11:33 2010
@@ -3000,7 +3000,7 @@
// Walk through identifiers in external identifier sources.
if (IdentifierInfoLookup *External
= Context.Idents.getExternalIdentifierLookup()) {
- IdentifierIterator *Iter = External->getIdentifiers();
+ llvm::OwningPtr<IdentifierIterator> Iter(External->getIdentifiers());
do {
llvm::StringRef Name = Iter->Next();
if (Name.empty())
More information about the cfe-commits
mailing list