From efade4380b460acbab9e0786e1f533a2451e3268 Mon Sep 17 00:00:00 2001 From: Kyungwook Tak Date: Fri, 1 Jul 2016 14:47:31 +0900 Subject: [PATCH] Fix bug in file visitor target handler Continue for loop without call recursive for target Change-Id: Ibda767ddecfe6582cb02fbc9585cacc35f87894d Signed-off-by: Kyungwook Tak --- src/framework/service/file-system.cpp | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/src/framework/service/file-system.cpp b/src/framework/service/file-system.cpp index 934654a..214761d 100644 --- a/src/framework/service/file-system.cpp +++ b/src/framework/service/file-system.cpp @@ -309,11 +309,12 @@ void FsVisitor::run(const DirPtr &dirptr, const FilePtr ¤tdir) } } - if (this->m_isBasedOnName && ncurrentdir->isInApp()) + if (this->m_isBasedOnName && ncurrentdir->isInApp()) { this->m_targetHandler(ncurrentdir); - - DEBUG("recurse dir : " << fullpath); - this->run(ndirptr, ncurrentdir); + } else { + DEBUG("recurse dir : " << fullpath); + this->run(ndirptr, ncurrentdir); + } } else if (result->d_type == DT_REG) { try { auto fileptr = File::createIfModified(fullpath, currentdir, this->m_since); -- 2.7.4