diff --git a/Source/kwsys/SystemTools.cxx b/Source/kwsys/SystemTools.cxx index 33d3632eb5..e30cc51985 100644 --- a/Source/kwsys/SystemTools.cxx +++ b/Source/kwsys/SystemTools.cxx @@ -1950,9 +1950,12 @@ kwsys_stl::string SystemTools::FindProgram( { path.push_back(*i); } - for(kwsys_stl::vector::const_iterator p = path.begin(); + for(kwsys_stl::vector::iterator p = path.begin(); p != path.end(); ++p) { +#ifdef _WIN32 + SystemTools::ReplaceString(*p, "\"", ""); +#endif tryPath = *p; tryPath += "/"; tryPath += name;