From ae63ae6a6e48d2c502c7318dce66398183e6dbe4 Mon Sep 17 00:00:00 2001 From: Andy Cedilnik Date: Wed, 16 Feb 2005 16:06:11 -0500 Subject: [PATCH] BUG: Report errors --- Source/CTest/cmCTestEmptyBinaryDirectoryCommand.cxx | 6 +++++- Source/CTest/cmCTestScriptHandler.cxx | 5 ++++- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/Source/CTest/cmCTestEmptyBinaryDirectoryCommand.cxx b/Source/CTest/cmCTestEmptyBinaryDirectoryCommand.cxx index 90d88ce4f..024ed21fd 100644 --- a/Source/CTest/cmCTestEmptyBinaryDirectoryCommand.cxx +++ b/Source/CTest/cmCTestEmptyBinaryDirectoryCommand.cxx @@ -27,7 +27,11 @@ bool cmCTestEmptyBinaryDirectoryCommand::InitialPass( return false; } - cmCTestScriptHandler::EmptyBinaryDirectory(args[0].c_str()); + if ( !cmCTestScriptHandler::EmptyBinaryDirectory(args[0].c_str()) ) + { + this->SetError("problem removing the binary directory"); + return false; + } return true; } diff --git a/Source/CTest/cmCTestScriptHandler.cxx b/Source/CTest/cmCTestScriptHandler.cxx index b91147c40..d1e89dfa7 100644 --- a/Source/CTest/cmCTestScriptHandler.cxx +++ b/Source/CTest/cmCTestScriptHandler.cxx @@ -574,7 +574,10 @@ int cmCTestScriptHandler::RunConfigurationDashboard() // clear the binary directory? if (m_EmptyBinDir) { - cmCTestScriptHandler::EmptyBinaryDirectory(m_BinaryDir.c_str()); + if ( !cmCTestScriptHandler::EmptyBinaryDirectory(m_BinaryDir.c_str()) ) + { + std::cerr << "Problem removing the binary directory" << std::endl; + } } // make sure the binary directory exists if it isn't the srcdir