| Index: base/files/file_util_posix.cc
|
| diff --git a/base/files/file_util_posix.cc b/base/files/file_util_posix.cc
|
| index a8db2599c642ff920e87533f0bcb6566a7253168..34a1c4d1e6e2481a953ad2fac5d30ddb124ca3cd 100644
|
| --- a/base/files/file_util_posix.cc
|
| +++ b/base/files/file_util_posix.cc
|
| @@ -276,11 +276,8 @@ bool CopyDirectory(const FilePath& from_path,
|
| FilePath real_from_path = MakeAbsoluteFilePath(from_path);
|
| if (real_from_path.empty())
|
| return false;
|
| - if (real_to_path.value().size() >= real_from_path.value().size() &&
|
| - real_to_path.value().compare(0, real_from_path.value().size(),
|
| - real_from_path.value()) == 0) {
|
| + if (real_to_path == real_from_path || real_from_path.IsParent(real_to_path))
|
| return false;
|
| - }
|
|
|
| int traverse_type = FileEnumerator::FILES | FileEnumerator::SHOW_SYM_LINKS;
|
| if (recursive)
|
|
|