summaryrefslogtreecommitdiffstats
path: root/Source/ctest.cxx
diff options
context:
space:
mode:
authorBrad King <brad.king@kitware.com>2013-02-08 18:38:43 (GMT)
committerCMake Topic Stage <kwrobot@kitware.com>2013-02-08 18:38:43 (GMT)
commitf4d1474013aeb51bdedbbd2493b4d7b337f444a6 (patch)
tree271dacdcecd89f70f43688167c62420294587005 /Source/ctest.cxx
parente8df4cab82914f061752bc3e6b9a8a6498b1485b (diff)
parenta943b5c4f3ed700f53c554b9f91942ad57047c18 (diff)
downloadCMake-f4d1474013aeb51bdedbbd2493b4d7b337f444a6.zip
CMake-f4d1474013aeb51bdedbbd2493b4d7b337f444a6.tar.gz
CMake-f4d1474013aeb51bdedbbd2493b4d7b337f444a6.tar.bz2
Merge topic 'exit-without-working-directory'
a943b5c Fail early if no current working directory exists
Diffstat (limited to 'Source/ctest.cxx')
-rw-r--r--Source/ctest.cxx5
1 files changed, 2 insertions, 3 deletions
diff --git a/Source/ctest.cxx b/Source/ctest.cxx
index d650777..8de901a 100644
--- a/Source/ctest.cxx
+++ b/Source/ctest.cxx
@@ -273,14 +273,13 @@ int main (int argc, char *argv[])
return cmCTestLaunch::Main(argc, argv);
}
- int nocwd = 0;
cmCTest inst;
if ( cmSystemTools::GetCurrentWorkingDirectory().size() == 0 )
{
cmCTestLog(&inst, ERROR_MESSAGE,
"Current working directory cannot be established." << std::endl);
- nocwd = 1;
+ return 1;
}
// If there is a testing input file, check for documentation options
@@ -298,7 +297,7 @@ int main (int argc, char *argv[])
}
cmDocumentation doc;
doc.addCTestStandardDocSections();
- if(doc.CheckOptions(argc, argv) || nocwd)
+ if(doc.CheckOptions(argc, argv))
{
// Construct and print requested documentation.
std::vector<cmDocumentationEntry> commands;