BUG: Avoid double-slash in check for source file

This commit is contained in:
Brad King 2008-07-30 11:06:06 -04:00
parent d6f02cd911
commit 24c9434a81
1 changed files with 5 additions and 2 deletions

View File

@ -113,8 +113,11 @@ void cmSourceFileLocation::UpdateExtension(const char* name)
tryPath = this->Makefile->GetCurrentDirectory(); tryPath = this->Makefile->GetCurrentDirectory();
tryPath += "/"; tryPath += "/";
} }
if(!this->Directory.empty())
{
tryPath += this->Directory; tryPath += this->Directory;
tryPath += "/"; tryPath += "/";
}
tryPath += this->Name; tryPath += this->Name;
if(cmSystemTools::FileExists(tryPath.c_str(), true)) if(cmSystemTools::FileExists(tryPath.c_str(), true))
{ {