forked from OSchip/llvm-project
[msan] Advance before destroying entry
-fsanitize-memory-use-after-dtor reports this memory access.
This commit is contained in:
parent
153dee34f1
commit
0d0a99cb96
|
@ -434,8 +434,8 @@ void PathDiagnosticConsumer::FlushDiagnostics(
|
|||
}
|
||||
|
||||
PathDiagnosticConsumer::FilesMade::~FilesMade() {
|
||||
for (PDFileEntry &Entry : Set)
|
||||
Entry.~PDFileEntry();
|
||||
for (auto It = Set.begin(); It != Set.end();)
|
||||
(It++)->~PDFileEntry();
|
||||
}
|
||||
|
||||
void PathDiagnosticConsumer::FilesMade::addDiagnostic(const PathDiagnostic &PD,
|
||||
|
|
Loading…
Reference in New Issue