[cfe-commits] r49907 - in /cfe/trunk/lib/Analysis: CFRefCount.cpp GRCoreEngine.cpp
Ted Kremenek
kremenek at apple.com
Fri Apr 18 09:30:14 PDT 2008
Author: kremenek
Date: Fri Apr 18 11:30:14 2008
New Revision: 49907
URL: http://llvm.org/viewvc/llvm-project?rev=49907&view=rev
Log:
Fixed bug in GREndPathNodeBuilder: only return a node if it wasn't in the node cache.
Modified:
cfe/trunk/lib/Analysis/CFRefCount.cpp
cfe/trunk/lib/Analysis/GRCoreEngine.cpp
Modified: cfe/trunk/lib/Analysis/CFRefCount.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Analysis/CFRefCount.cpp?rev=49907&r1=49906&r2=49907&view=diff
==============================================================================
--- cfe/trunk/lib/Analysis/CFRefCount.cpp (original)
+++ cfe/trunk/lib/Analysis/CFRefCount.cpp Fri Apr 18 11:30:14 2008
@@ -1065,6 +1065,10 @@
}
ExplodedNode<ValueState>* N = Builder.MakeNode(St);
+
+ if (!N)
+ return;
+
std::vector<SymbolID>*& LeaksAtNode = Leaks[N];
assert (!LeaksAtNode);
LeaksAtNode = new std::vector<SymbolID>();
Modified: cfe/trunk/lib/Analysis/GRCoreEngine.cpp
URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/Analysis/GRCoreEngine.cpp?rev=49907&r1=49906&r2=49907&view=diff
==============================================================================
--- cfe/trunk/lib/Analysis/GRCoreEngine.cpp (original)
+++ cfe/trunk/lib/Analysis/GRCoreEngine.cpp Fri Apr 18 11:30:14 2008
@@ -456,7 +456,8 @@
if (IsNew) {
Node->markAsSink();
Eng.G->addEndOfPath(Node);
+ return Node;
}
- return Node;
+ return NULL;
}
More information about the cfe-commits
mailing list