diff options
| author | John McCall <rjmccall@apple.com> | 2011-04-06 09:02:12 +0000 |
|---|---|---|
| committer | John McCall <rjmccall@apple.com> | 2011-04-06 09:02:12 +0000 |
| commit | 3337ca5f959d0cc425b30d762efaac4684256c40 (patch) | |
| tree | cea8116ab95b82d83c419c0f0ab99a41d1ce65c6 /clang/lib/StaticAnalyzer/Core/CFRefCount.cpp | |
| parent | ce5d9aedb9d233fed536aafeef587388412dd5bf (diff) | |
| download | bcm5719-llvm-3337ca5f959d0cc425b30d762efaac4684256c40.tar.gz bcm5719-llvm-3337ca5f959d0cc425b30d762efaac4684256c40.zip | |
When updating the retain summary based on {cf,ns}_consumed attributes,
be sure to consume the argument index that actually had the attribute
rather than always the first. rdar://problem/9234108
llvm-svn: 128998
Diffstat (limited to 'clang/lib/StaticAnalyzer/Core/CFRefCount.cpp')
| -rw-r--r-- | clang/lib/StaticAnalyzer/Core/CFRefCount.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/StaticAnalyzer/Core/CFRefCount.cpp b/clang/lib/StaticAnalyzer/Core/CFRefCount.cpp index 416e1209ae6..5131c739257 100644 --- a/clang/lib/StaticAnalyzer/Core/CFRefCount.cpp +++ b/clang/lib/StaticAnalyzer/Core/CFRefCount.cpp @@ -1201,7 +1201,7 @@ RetainSummaryManager::updateSummaryFromAnnotations(RetainSummary &Summ, // Effects on the parameters. unsigned parm_idx = 0; for (FunctionDecl::param_const_iterator pi = FD->param_begin(), - pe = FD->param_end(); pi != pe; ++pi) { + pe = FD->param_end(); pi != pe; ++pi, ++parm_idx) { const ParmVarDecl *pd = *pi; if (pd->getAttr<NSConsumedAttr>()) { if (!GCEnabled) |

