llvm.org GIT mirror llvm / 542c063
Path::GetTemporaryDirectory(): Add an assertion if TempDirectory is alive, to check when someone would remove the tempdir. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@157529 91177308-0d34-0410-b5e6-96231b3b80d8 NAKAMURA Takumi 8 years ago
1 changed file(s) with 3 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
187187
188188 Path
189189 Path::GetTemporaryDirectory(std::string* ErrMsg) {
190 if (TempDirectory)
190 if (TempDirectory) {
191 assert(TempDirectory->exists() && "Who has removed TempDirectory?");
191192 return *TempDirectory;
193 }
192194
193195 char pathname[MAX_PATH];
194196 if (!GetTempPath(MAX_PATH, pathname)) {