forked from OSchip/llvm-project
Fixed memory leak in unit test introduced in my previous commit r322503
llvm-svn: 322513
This commit is contained in:
parent
1393ccf949
commit
3d24630c7b
|
@ -592,6 +592,9 @@ TEST_F(LibclangReparseTest, PreprocessorSkippedRanges) {
|
|||
if (i == 2)
|
||||
flags |= CXTranslationUnit_CreatePreambleOnFirstParse;
|
||||
|
||||
if (i != 0)
|
||||
clang_disposeTranslationUnit(ClangTU); // dispose from previous iter
|
||||
|
||||
// parse once
|
||||
ClangTU = clang_parseTranslationUnit(Index, Main.c_str(), nullptr, 0,
|
||||
nullptr, 0, flags);
|
||||
|
|
Loading…
Reference in New Issue