From d1792c48d5b5171541fbf425e125ba61dbf89b82 Mon Sep 17 00:00:00 2001 From: Brad King Date: Thu, 6 Mar 2025 10:58:12 -0500 Subject: cmake-gui: Suppress incidental error messages while choosing build tree Avoid printing Error: is not a directory to the console for every update to the GUI's build directory widget. --- Source/cmake.cxx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Source/cmake.cxx b/Source/cmake.cxx index 51731df..a096521 100644 --- a/Source/cmake.cxx +++ b/Source/cmake.cxx @@ -4016,7 +4016,9 @@ bool cmake::Open(std::string const& dir, DryRun dryRun) this->SetHomeDirectory(""); this->SetHomeOutputDirectory(""); if (!cmSystemTools::FileIsDirectory(dir)) { - std::cerr << "Error: " << dir << " is not a directory\n"; + if (dryRun == DryRun::No) { + std::cerr << "Error: " << dir << " is not a directory\n"; + } return false; } -- cgit v0.12