Fix a thinko in the creation of temporary files for the precompiled preamble

llvm-svn: 110804
This commit is contained in:
Douglas Gregor 2010-08-11 13:06:56 +00:00
parent 1c28331b57
commit 20975b25c3
1 changed files with 2 additions and 1 deletions

View File

@ -561,10 +561,11 @@ static std::string GetPreamblePCHPath() {
TmpDir = "/tmp";
llvm::sys::Path P(TmpDir);
P.appendComponent("preamble");
P.appendSuffix("pch");
if (P.createTemporaryFileOnDisk())
return std::string();
P.appendSuffix("pch");
fprintf(stderr, "Preamble file: %s\n", P.str().c_str());
return P.str();
}