summaryrefslogtreecommitdiffstats
path: root/base/file_util_mac.mm
diff options
context:
space:
mode:
authormaruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-02-06 03:42:39 +0000
committermaruel@chromium.org <maruel@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-02-06 03:42:39 +0000
commit94b9692d6e851e24df069d2bf2da256b9660766b (patch)
tree5a2ed8844d582aead79246980b13f95a31eedf2c /base/file_util_mac.mm
parent0813d3eb2f83ac5bf8bd069c68780c240ad27002 (diff)
downloadchromium_src-94b9692d6e851e24df069d2bf2da256b9660766b.zip
chromium_src-94b9692d6e851e24df069d2bf2da256b9660766b.tar.gz
chromium_src-94b9692d6e851e24df069d2bf2da256b9660766b.tar.bz2
Modify CopyFileUnsafe() on OSX to stop copying ACL.
This makes CopyFile() and CopyDirectory() behavior consistent on OSX to the other platforms. Stop copying the ACL on the files copied. This means the destination file will inherit from the umask or inherited ACL from the destination parent directory, which is sane. This matches what is done on linux. This will fixes unit tests that copy files from a read only directory into a temporary directory so they can be safely be modified, otherwise the file acl would have to be modified everytime. While base_unittests didn't care, it blew up disk cache tests in net_unittests. R=thakis@chromium.org BUG=116251,335420 Review URL: https://codereview.chromium.org/132183007 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@249258 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'base/file_util_mac.mm')
-rw-r--r--base/file_util_mac.mm2
1 files changed, 1 insertions, 1 deletions
diff --git a/base/file_util_mac.mm b/base/file_util_mac.mm
index f8a6b63..7a99426 100644
--- a/base/file_util_mac.mm
+++ b/base/file_util_mac.mm
@@ -19,7 +19,7 @@ namespace internal {
bool CopyFileUnsafe(const FilePath& from_path, const FilePath& to_path) {
ThreadRestrictions::AssertIOAllowed();
return (copyfile(from_path.value().c_str(),
- to_path.value().c_str(), NULL, COPYFILE_ALL) == 0);
+ to_path.value().c_str(), NULL, COPYFILE_DATA) == 0);
}
} // namespace internal