diff options
author | Jordan Rose <jordan_rose@apple.com> | 2012-08-03 23:09:01 +0000 |
---|---|---|
committer | Jordan Rose <jordan_rose@apple.com> | 2012-08-03 23:09:01 +0000 |
commit | cfb4eb293fd8be1d3d247690f65606836431d1c1 (patch) | |
tree | e1241953b9bcb7d48ad8745d9c310a6e2e5625d4 /clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp | |
parent | 3eb3cd45b82855486b79e6a01add7899f07970fb (diff) | |
download | bcm5719-llvm-cfb4eb293fd8be1d3d247690f65606836431d1c1.tar.gz bcm5719-llvm-cfb4eb293fd8be1d3d247690f65606836431d1c1.zip |
[analyzer] When a symbol is null, we should track its constraints.
Because of this, we would previously emit NO path notes when a parameter
is constrained to null (because there are no stores). Now we show where we
made the assumption, which is much more useful.
llvm-svn: 161280
Diffstat (limited to 'clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp')
-rw-r--r-- | clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp b/clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp index 69373749a23..483082a37f4 100644 --- a/clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp +++ b/clang/lib/StaticAnalyzer/Checkers/CStringChecker.cpp @@ -252,8 +252,7 @@ ProgramStateRef CStringChecker::checkNonNull(CheckerContext &C, BugReport *report = new BugReport(*BT, os.str(), N); report->addRange(S->getSourceRange()); - report->addVisitor(bugreporter::getTrackNullOrUndefValueVisitor(N, S, - report)); + bugreporter::addTrackNullOrUndefValueVisitor(N, S, report); C.EmitReport(report); return NULL; } |