diff options
author | Ted Kremenek <kremenek@apple.com> | 2011-01-25 19:13:42 +0000 |
---|---|---|
committer | Ted Kremenek <kremenek@apple.com> | 2011-01-25 19:13:42 +0000 |
commit | 7fd987de238ec95f555241e93fedd495651d31ff (patch) | |
tree | 651cd452b3e95aca18b9772ace5d1bd3bf839a54 /clang/lib/StaticAnalyzer/Checkers/UndefCapturedBlockVarChecker.cpp | |
parent | 2d525f08c2d96cb1358266990be990cfbd31a40a (diff) | |
download | bcm5719-llvm-7fd987de238ec95f555241e93fedd495651d31ff.tar.gz bcm5719-llvm-7fd987de238ec95f555241e93fedd495651d31ff.zip |
Tweak wording of static analyzer diagnostic
for a block capturing the value of an uninitialized
variable.
llvm-svn: 124212
Diffstat (limited to 'clang/lib/StaticAnalyzer/Checkers/UndefCapturedBlockVarChecker.cpp')
-rw-r--r-- | clang/lib/StaticAnalyzer/Checkers/UndefCapturedBlockVarChecker.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/clang/lib/StaticAnalyzer/Checkers/UndefCapturedBlockVarChecker.cpp b/clang/lib/StaticAnalyzer/Checkers/UndefCapturedBlockVarChecker.cpp index 57e698bb7c2..1aaaa68ca61 100644 --- a/clang/lib/StaticAnalyzer/Checkers/UndefCapturedBlockVarChecker.cpp +++ b/clang/lib/StaticAnalyzer/Checkers/UndefCapturedBlockVarChecker.cpp @@ -82,14 +82,14 @@ UndefCapturedBlockVarChecker::PostVisitBlockExpr(CheckerContext &C, if (state->getSVal(VR).isUndef()) if (ExplodedNode *N = C.generateSink()) { if (!BT) - BT = new BuiltinBug("Captured block variable is uninitialized"); + BT = new BuiltinBug("uninitialized variable captured by block"); // Generate a bug report. llvm::SmallString<128> buf; llvm::raw_svector_ostream os(buf); - os << "Variable '" << VD->getName() << "' is captured by block with " - "a garbage value"; + os << "Variable '" << VD->getName() + << "' is uninitialized when captured by block"; EnhancedBugReport *R = new EnhancedBugReport(*BT, os.str(), N); if (const Expr *Ex = FindBlockDeclRefExpr(BE->getBody(), VD)) |