diff options
Diffstat (limited to 'netwerk/base/nsIncrementalDownload.cpp')
-rw-r--r-- | netwerk/base/nsIncrementalDownload.cpp | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/netwerk/base/nsIncrementalDownload.cpp b/netwerk/base/nsIncrementalDownload.cpp index 42cd6faa5..47f7cb98b 100644 --- a/netwerk/base/nsIncrementalDownload.cpp +++ b/netwerk/base/nsIncrementalDownload.cpp @@ -49,27 +49,6 @@ WriteToFile(nsIFile *lf, const char *data, uint32_t len, int32_t flags) PRFileDesc *fd; int32_t mode = 0600; nsresult rv; -#if defined(MOZ_WIDGET_GONK) - // The sdcard on a B2G phone looks like: - // d---rwx--- system sdcard_rw 1970-01-01 01:00:00 sdcard - // On the emulator, xpcshell fails when using 0600 mode to open the file, - // and 0660 works. - nsCOMPtr<nsIFile> parent; - rv = lf->GetParent(getter_AddRefs(parent)); - if (NS_FAILED(rv)) { - return rv; - } - uint32_t parentPerm; - rv = parent->GetPermissions(&parentPerm); - if (NS_FAILED(rv)) { - return rv; - } - if ((parentPerm & 0700) == 0) { - // Parent directory has no owner-write, so try to use group permissions - // instead of owner permissions. - mode = 0660; - } -#endif rv = lf->OpenNSPRFileDesc(flags, mode, &fd); if (NS_FAILED(rv)) return rv; |