Commit e178bd46 authored by Brad King's avatar Brad King

cmake-gui: Fix "Open Project" for VS IDE with space in path

Do not encode the path for a shell until after we check that it exists.

Fixes: #18501
parent fd025389
......@@ -878,12 +878,13 @@ bool cmGlobalVisualStudioGenerator::Open(const std::string& bindir,
const std::string& projectName,
bool dryRun)
std::string buildDir = cmSystemTools::ConvertToOutputPath(bindir);
std::string sln = buildDir + "\\" + projectName + ".sln";
std::string sln = bindir + "/" + projectName + ".sln";
if (dryRun) {
return cmSystemTools::FileExists(sln, true);
sln = cmSystemTools::ConvertToOutputPath(sln);
return std::async(std::launch::async, OpenSolution, sln).get();
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment