diff options
| author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2014-02-27 04:11:59 +0000 |
|---|---|---|
| committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2014-02-27 04:11:59 +0000 |
| commit | 0242440d9fdc32a81fa397445d5a8b599875e446 (patch) | |
| tree | 2623bc10d748085b2db647311c1dd9ffaf6ef17a /lib/Serialization/ModuleManager.cpp | |
| parent | 70549826ec94c46f875cd4ec0429d44bb388ab65 (diff) | |
| download | clang-0242440d9fdc32a81fa397445d5a8b599875e446.tar.gz clang-0242440d9fdc32a81fa397445d5a8b599875e446.tar.bz2 clang-0242440d9fdc32a81fa397445d5a8b599875e446.tar.xz | |
[ASTUnit] Fix use-after-free bug in ASTUnit::getMainBufferWithPrecompiledPreamble().
With r197755 we started reading the contents of buffer file entries, but the
buffers may point to ASTReader blobs that have been disposed.
Fix this by having the CompilerInstance object keep a reference to the ASTReader
as well as having the ASTContext keep reference to the ExternalASTSource.
This was very difficult to construct a test case for.
rdar://16149782
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@202346 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Serialization/ModuleManager.cpp')
0 files changed, 0 insertions, 0 deletions
