]> granicus.if.org Git - clang/commitdiff
Make sure temporary files are deleted when recovering from a crash when compiling...
authorBenjamin Kramer <benny.kra@googlemail.com>
Sun, 14 Oct 2012 19:50:53 +0000 (19:50 +0000)
committerBenjamin Kramer <benny.kra@googlemail.com>
Sun, 14 Oct 2012 19:50:53 +0000 (19:50 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@165911 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Frontend/CompilerInstance.cpp

index c50a651444670b095090cf2638904b8e2753f033..a8cafdbfeff89d5db9ca5b688d9d79e3163b99b6 100644 (file)
@@ -837,6 +837,7 @@ static void compileModule(CompilerInstance &ImportingInstance,
   // FIXME: Even though we're executing under crash protection, it would still
   // be nice to do this with RemoveFileOnSignal when we can. However, that
   // doesn't make sense for all clients, so clean this up manually.
+  Instance.clearOutputFiles(/*EraseFiles=*/true);
   if (!TempModuleMapFileName.empty())
     llvm::sys::Path(TempModuleMapFileName).eraseFromDisk();
 }