[analyzer]SimpleStreamChecker: add a TODO for better leak report.

llvm-svn: 167001
This commit is contained in:
Anna Zaks 2012-10-30 04:18:21 +00:00
parent 302da83fc2
commit 92d96604d5
1 changed files with 2 additions and 0 deletions

View File

@ -205,10 +205,12 @@ ExplodedNode *SimpleStreamChecker::reportLeaks(SymbolVector LeakedStreams,
}
// Attach bug reports to the leak node.
// TODO: Identify the leaked file descriptor.
for (llvm::SmallVector<SymbolRef, 2>::iterator
I = LeakedStreams.begin(), E = LeakedStreams.end(); I != E; ++I) {
BugReport *R = new BugReport(*LeakBugType,
"Opened file is never closed; potential resource leak", ErrNode);
R->markInteresting(*I);
C.EmitReport(R);
}