From eff2623f1042ea88df8c748ccae7fffca591bb87 Mon Sep 17 00:00:00 2001 From: Eugene Sandulenko Date: Mon, 16 Aug 2010 18:07:21 +0000 Subject: OSYSTEM: revert r52120 and r52121. Introduced regressions svn-id: r52127 --- common/fs.cpp | 34 ++-------------------------------- 1 file changed, 2 insertions(+), 32 deletions(-) diff --git a/common/fs.cpp b/common/fs.cpp index b65d03a690..87067df2cc 100644 --- a/common/fs.cpp +++ b/common/fs.cpp @@ -314,27 +314,10 @@ int FSDirectory::listMatchingMembers(ArchiveMemberList &list, const String &patt NodeCache::iterator it = _fileCache.begin(); for ( ; it != _fileCache.end(); ++it) { if (it->_key.matchString(lowercasePattern, false, true)) { - if (_flat) - list.push_back(ArchiveMemberPtr(new FSNode(it->_value))); - else - list.push_back(ArchiveMemberPtr(new FSNode(it->_key))); - + list.push_back(ArchiveMemberPtr(new FSNode(it->_value))); matches++; } } - - // If non-flat directory was created, include directories in the match too - if (!_flat) { - it = _subDirCache.begin(); - for ( ; it != _subDirCache.end(); ++it) { - if (it->_key.matchString(lowercasePattern, false, true)) { - list.push_back(ArchiveMemberPtr(new FSNode(it->_key + "/"))); - - matches++; - } - } - } - return matches; } @@ -347,23 +330,10 @@ int FSDirectory::listMembers(ArchiveMemberList &list) { int files = 0; for (NodeCache::iterator it = _fileCache.begin(); it != _fileCache.end(); ++it) { - if (_flat) - list.push_back(ArchiveMemberPtr(new FSNode(it->_value))); - else - list.push_back(ArchiveMemberPtr(new FSNode(it->_key))); - + list.push_back(ArchiveMemberPtr(new FSNode(it->_value))); ++files; } - // If non-flat directory was created, include directories in the list too - if (!_flat) { - for (NodeCache::iterator it = _subDirCache.begin(); it != _subDirCache.end(); ++it) { - list.push_back(ArchiveMemberPtr(new FSNode(it->_key + "/"))); - - ++files; - } - } - return files; } -- cgit v1.2.3