Index: chrome/common/extensions/extension_file_util.cc |
diff --git a/chrome/common/extensions/extension_file_util.cc b/chrome/common/extensions/extension_file_util.cc |
index 566779b9e1ae0fb56e6e18b69539ef7d28837f3a..d277b477385f1733e8a433aa5d04017be2b9f69b 100644 |
--- a/chrome/common/extensions/extension_file_util.cc |
+++ b/chrome/common/extensions/extension_file_util.cc |
@@ -8,6 +8,7 @@ |
#include <vector> |
#include "base/file_util.h" |
+#include "base/files/file_enumerator.h" |
#include "base/files/file_path.h" |
#include "base/files/scoped_temp_dir.h" |
#include "base/json/json_file_value_serializer.h" |
@@ -202,8 +203,8 @@ std::vector<base::FilePath> FindPrivateKeyFiles( |
const base::FilePath& extension_dir) { |
std::vector<base::FilePath> result; |
// Pattern matching only works at the root level, so filter manually. |
- file_util::FileEnumerator traversal(extension_dir, /*recursive=*/true, |
- file_util::FileEnumerator::FILES); |
+ base::FileEnumerator traversal(extension_dir, /*recursive=*/true, |
+ base::FileEnumerator::FILES); |
for (base::FilePath current = traversal.Next(); !current.empty(); |
current = traversal.Next()) { |
if (!current.MatchesExtension(chrome::kExtensionKeyFileExtension)) |
@@ -331,9 +332,9 @@ void GarbageCollectExtensions( |
return; |
DVLOG(1) << "Garbage collecting extensions..."; |
- file_util::FileEnumerator enumerator(install_directory, |
- false, // Not recursive. |
- file_util::FileEnumerator::DIRECTORIES); |
+ base::FileEnumerator enumerator(install_directory, |
+ false, // Not recursive. |
+ base::FileEnumerator::DIRECTORIES); |
base::FilePath extension_path; |
for (extension_path = enumerator.Next(); !extension_path.value().empty(); |
extension_path = enumerator.Next()) { |
@@ -378,10 +379,10 @@ void GarbageCollectExtensions( |
} |
// Clean up old version directories. |
- file_util::FileEnumerator versions_enumerator( |
+ base::FileEnumerator versions_enumerator( |
extension_path, |
false, // Not recursive. |
- file_util::FileEnumerator::DIRECTORIES); |
+ base::FileEnumerator::DIRECTORIES); |
for (base::FilePath version_dir = versions_enumerator.Next(); |
!version_dir.value().empty(); |
version_dir = versions_enumerator.Next()) { |
@@ -471,9 +472,8 @@ bool CheckForIllegalFilenames(const base::FilePath& extension_path, |
// There is a problem when using pattern "_*" with FileEnumerator, so we have |
// to cheat with find_first_of and match all. |
const int kFilesAndDirectories = |
- file_util::FileEnumerator::DIRECTORIES | file_util::FileEnumerator::FILES; |
- file_util::FileEnumerator all_files( |
- extension_path, false, kFilesAndDirectories); |
+ base::FileEnumerator::DIRECTORIES | base::FileEnumerator::FILES; |
+ base::FileEnumerator all_files(extension_path, false, kFilesAndDirectories); |
base::FilePath file; |
while (!(file = all_files.Next()).empty()) { |