@@ -362,6 +362,7 @@ inline void Rule::executeTransformation(actions::Action *a,
362
362
if (m_containsMultiMatchAction) {
363
363
std::shared_ptr<std::string> t (new std::string (a->m_name ));
364
364
ret->push_back (std::make_pair (u, t));
365
+ (*nth)++;
365
366
}
366
367
*value = u;
367
368
}
@@ -378,7 +379,6 @@ inline void Rule::executeTransformation(actions::Action *a,
378
379
a->m_name + " : \" " + \
379
380
utils::string::limitTo (80 , newValue) +" \" " );
380
381
#endif
381
- (*nth)++;
382
382
}
383
383
384
384
@@ -396,10 +396,7 @@ std::list<std::pair<std::shared_ptr<std::string>,
396
396
397
397
if (m_containsMultiMatchAction == true ) {
398
398
ret.push_back (std::make_pair (
399
- std::shared_ptr<std::string>(value),
400
- std::shared_ptr<std::string>(new std::string (path))));
401
- ret.push_back (std::make_pair (
402
- std::shared_ptr<std::string>(value),
399
+ std::shared_ptr<std::string>(new std::string (*value)),
403
400
std::shared_ptr<std::string>(new std::string (path))));
404
401
}
405
402
@@ -461,17 +458,16 @@ std::list<std::pair<std::shared_ptr<std::string>,
461
458
}
462
459
463
460
if (m_containsMultiMatchAction == true ) {
464
- // v2 checks the last entry twice. Don't know why.
465
- ret.push_back (ret.back ());
466
-
467
461
#ifndef NO_LOGS
468
462
trans->debug (9 , " multiMatch is enabled. " \
469
463
+ std::to_string (ret.size ()) + \
470
464
" values to be tested." );
471
465
#endif
472
- } else {
466
+ }
467
+
468
+ if (!m_containsMultiMatchAction) {
473
469
ret.push_back (std::make_pair (
474
- value,
470
+ std::shared_ptr<std::string>( new std::string (* value)) ,
475
471
std::shared_ptr<std::string>(new std::string (path))));
476
472
}
477
473
0 commit comments