diff --git a/Source/cmForEachCommand.cxx b/Source/cmForEachCommand.cxx index 84b83907d..e4cca41d3 100644 --- a/Source/cmForEachCommand.cxx +++ b/Source/cmForEachCommand.cxx @@ -85,8 +85,11 @@ ScopeEnded(cmMakefile &mf) mf.GetCurrentDirectory()); } -bool cmForEachCommand::InitialPass(std::vector const& args) +bool cmForEachCommand::InitialPass(std::vector const& argsIn) { + std::vector args; + cmSystemTools::ExpandListArguments(argsIn, args); + if(args.size() < 2 ) { this->SetError("called with incorrect number of arguments");