summaryrefslogtreecommitdiffstats
path: root/clang/lib/Analysis/BugReporterVisitors.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'clang/lib/Analysis/BugReporterVisitors.cpp')
-rw-r--r--clang/lib/Analysis/BugReporterVisitors.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/clang/lib/Analysis/BugReporterVisitors.cpp b/clang/lib/Analysis/BugReporterVisitors.cpp
index 5c31066eff4..fce31e70f0b 100644
--- a/clang/lib/Analysis/BugReporterVisitors.cpp
+++ b/clang/lib/Analysis/BugReporterVisitors.cpp
@@ -63,7 +63,8 @@ clang::bugreporter::GetDenomExpr(const ExplodedNode *N) {
const Stmt*
clang::bugreporter::GetCalleeExpr(const ExplodedNode *N) {
- const Stmt *S = N->getLocationAs<PostStmt>()->getStmt();
+ // Callee is checked as a PreVisit to the CallExpr.
+ const Stmt *S = N->getLocationAs<PreStmt>()->getStmt();
if (const CallExpr *CE = dyn_cast<CallExpr>(S))
return CE->getCallee();
return NULL;
OpenPOWER on IntegriCloud