ctest: fix add_subdirectory() crash

The directory is at args[0], not args[1].  Introduced in commit
v2.6.0~489 (... 5889 ... tests are not found in some cases when using
add_subdirectory ..., 2008-01-18).
This commit is contained in:
Ben Boeckel 2015-07-24 14:23:13 -04:00 committed by Brad King
parent 3a0db0223b
commit 64821e8a40
1 changed files with 1 additions and 1 deletions

View File

@ -176,7 +176,7 @@ bool cmCTestAddSubdirectoryCommand
cmSystemTools::ChangeDirectory(cwd); cmSystemTools::ChangeDirectory(cwd);
std::string fname = cwd; std::string fname = cwd;
fname += "/"; fname += "/";
fname += args[1]; fname += args[0];
if ( !cmSystemTools::FileExists(fname.c_str()) ) if ( !cmSystemTools::FileExists(fname.c_str()) )
{ {