diff options
Diffstat (limited to 'lib/Analysis/BugReporter.cpp')
-rw-r--r-- | lib/Analysis/BugReporter.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Analysis/BugReporter.cpp b/lib/Analysis/BugReporter.cpp index 5047e71804..7637a1614c 100644 --- a/lib/Analysis/BugReporter.cpp +++ b/lib/Analysis/BugReporter.cpp @@ -789,7 +789,8 @@ static void GenExtAddEdge(PathDiagnostic& PD, if (const Stmt *PS = PrevLoc.asStmt()) if (const Stmt *NS = NewLoc.asStmt()) { const Stmt *parentPS = PDB.getParent(PS); - if (isa<CompoundStmt>(parentPS) && parentPS == PDB.getParent(NS)) + if (parentPS && isa<CompoundStmt>(parentPS) && + parentPS == PDB.getParent(NS)) return; } |