diff --git a/source/src/XMLParser.cc b/source/src/XMLParser.cc index 4bdab217..84afa29b 100644 --- a/source/src/XMLParser.cc +++ b/source/src/XMLParser.cc @@ -157,7 +157,11 @@ namespace marlin{ // preprocess groups: --------------------------------------------------------------------------------- // simply copy all group parameters to the processors // and then copy the processors to the root node - while( (section = root->IterateChildren( "group", section ) ) != 0 ){ + // 'section' comes from above as first execute child, get the next section so we + // do not cleanup the execute section in loop body below, only the groups + TiXmlNode* nextSection = root->IterateChildren("group", section); + while((section = nextSection) != 0){ + nextSection = root->IterateChildren("group", section); std::vector groupParams ;