aboutsummaryrefslogtreecommitdiff
path: root/Analysis/ExplodedGraph.cpp
diff options
context:
space:
mode:
authorTed Kremenek <kremenek@apple.com>2008-01-16 22:13:19 +0000
committerTed Kremenek <kremenek@apple.com>2008-01-16 22:13:19 +0000
commit160760e6326cf525bc48adf7fa1d414a049ba1f0 (patch)
tree948873875d920384b91ba6d63d2c6aa90f0e478e /Analysis/ExplodedGraph.cpp
parentaa66a32ba177338763cd0cf9df8310dfa2e24ff7 (diff)
Fixed iterator bug in ExplodedNodeImpl::NodeGroup::end(); we would improperly
handle the case where the number of nodes was 0. Fixed bug in GREngineImpl where we did not proceed to the next statement when processing a PostStmt location. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@46093 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'Analysis/ExplodedGraph.cpp')
-rw-r--r--Analysis/ExplodedGraph.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/Analysis/ExplodedGraph.cpp b/Analysis/ExplodedGraph.cpp
index 35e9d9de9a..1cfb02c787 100644
--- a/Analysis/ExplodedGraph.cpp
+++ b/Analysis/ExplodedGraph.cpp
@@ -60,7 +60,7 @@ ExplodedNodeImpl** ExplodedNodeImpl::NodeGroup::begin() const {
ExplodedNodeImpl** ExplodedNodeImpl::NodeGroup::end() const {
if (getKind() == Size1)
- return ((ExplodedNodeImpl**) &P)+1;
+ return (ExplodedNodeImpl**) (P ? &P+1 : &P);
else
return const_cast<ExplodedNodeImpl**>(&*(getVector(getPtr()).rbegin())+1);
}