@@ -393,32 +393,33 @@ CSYNC_EXCLUDE_TYPE ExcludedFiles::traversalPatternMatch(QStringView path, ItemTy
393393 bnameStr = path.mid (lastSlash + 1 );
394394 }
395395
396- QRegularExpressionMatch m ;
396+ QRegularExpressionMatch regularExpressionMatch ;
397397 if (filetype == ItemTypeDirectory) {
398- m = _bnameTraversalRegexDir.matchView (bnameStr);
398+ regularExpressionMatch = _bnameTraversalRegexDir.matchView (bnameStr);
399399 } else {
400- m = _bnameTraversalRegexFile.matchView (bnameStr);
400+ regularExpressionMatch = _bnameTraversalRegexFile.matchView (bnameStr);
401401 }
402- if (!m .hasMatch ())
402+ if (!regularExpressionMatch .hasMatch ())
403403 return CSYNC_NOT_EXCLUDED;
404- if (m .capturedStart (QStringLiteral (" exclude" )) != -1 ) {
404+ if (regularExpressionMatch .capturedStart (QStringLiteral (" exclude" )) != -1 ) {
405405 return CSYNC_FILE_EXCLUDE_LIST;
406- } else if (m .capturedStart (QStringLiteral (" excluderemove" )) != -1 ) {
406+ } else if (regularExpressionMatch .capturedStart (QStringLiteral (" excluderemove" )) != -1 ) {
407407 return CSYNC_FILE_EXCLUDE_AND_REMOVE;
408408 }
409409
410410 // third capture: full path matching is triggered
411411 QStringView pathStr = path;
412412
413413 if (filetype == ItemTypeDirectory) {
414- m = _fullTraversalRegexDir.matchView (pathStr);
414+ regularExpressionMatch = _fullTraversalRegexDir.matchView (pathStr);
415415 } else {
416- m = _fullTraversalRegexFile.matchView (pathStr);
416+ regularExpressionMatch = _fullTraversalRegexFile.matchView (pathStr);
417417 }
418- if (m .hasMatch ()) {
419- if (m .capturedStart (QStringLiteral (" exclude" )) != -1 ) {
418+ if (regularExpressionMatch .hasMatch ()) {
419+ if (regularExpressionMatch .capturedStart (QStringLiteral (" exclude" )) != -1 ) {
420420 return CSYNC_FILE_EXCLUDE_LIST;
421- } else if (m.capturedStart (QStringLiteral (" excluderemove" )) != -1 ) {
421+ }
422+ if (regularExpressionMatch.capturedStart (QStringLiteral (" excluderemove" )) != -1 ) {
422423 return CSYNC_FILE_EXCLUDE_AND_REMOVE;
423424 }
424425 }
0 commit comments