This reverts commit ed098a6dfc.
Revert "Bug 2043789: Use MakeRefPtr to do allocation for various RefPtr variables in xpcom/{io,ioutils}/. r=xpcom-reviewers,emilio"
This reverts commit aa8e617fd8.
Revert "Bug 2043788: Use MakeRefPtr to do allocation for various RefPtr variables in xpcom/{base,ds}/. r=xpcom-reviewers,emilio"
This reverts commit 4f52fb1147.
This is a large number of largely mechanical changes. When possible, the code
was called to directly call `.get()` instead, performing the assertions
manually. In many places PromiseFlatCString() calls were added to dynamically
copy the strings into null terminated buffers if the string was not null
terminated.
Differential Revision: https://phabricator.services.mozilla.com/D286158
This reverts commit e9790fa9ac.
Revert "Bug 1959738 - part 2 - Rewrite SanitizeFileName for better readability and correctness. r=Gijs"
This reverts commit d5b61ae198.
Revert "Bug 1959738 - Use a standard "_files" suffix for associated files folder in all locales. r=Gijs,mak"
This reverts commit 6eb038cba9.
All of the crashes looked at involve drives that might be prone to intermittent
failures or have unusual characteristics. While we could get something reported
that would be actionable it would be hard to find in the noise.
Differential Revision: https://phabricator.services.mozilla.com/D274736
We provide an alternate path if we can't determine whether the file we
are copying or moving is or isn't a directory. This information is only
required to potentially avoid a slow path, so in case we can't get it we
just continue with the copy/move operation and then unconditionally take
the slow path.
Differential Revision: https://phabricator.services.mozilla.com/D268845
Use the new API addition to Document portal allowing clients to get real
path to the exported document. This allows to still use the same path as
provided by the document portal, but display the path as exists on the
host side.
Differential Revision: https://phabricator.services.mozilla.com/D202717
Use the new API addition to Document portal allowing clients to get real
path to the exported document. This allows to still use the same path as
provided by the document portal, but display the path as exists on the
host side.
Differential Revision: https://phabricator.services.mozilla.com/D202717
We replace the use of FindFirstFileW by FindFirstFileExW with the most
optimized combination of flags on the code path reached from
nsIDirectoryEnumerator on Windows. This should make enumeration faster,
in particular when enumerating directories with thousands of files like
it can happen in QuotaManager code.
Differential Revision: https://phabricator.services.mozilla.com/D207151
`ERROR_INVALID_FUNCTION` appears to be a very generic "this device does not support this function".
Given that we deal only with file operations and errors here, this pretty much translates to "this device is not really a working file IO device for us" which makes it appear to be entirely broken for us.
Differential Revision: https://phabricator.services.mozilla.com/D196723
This avoids a syscall and also prevents a lot of unnecessary SeTcbPrivilege
requests which may be audited by security software.
Differential Revision: https://phabricator.services.mozilla.com/D170855
This adds `count` out parameter for recursive file remove calls to report the number of the removed entries.
Having a lot of files removed by `::Remove(recursive=true)` has been a problem, as a slow disk can cause a hang with such call. A counter feature will help us knowing the situation better via telemetry.
The use of out parameter here is to mark it optional and prevent unwanted changes in existing callers (because a return value can't be optional).
Differential Revision: https://phabricator.services.mozilla.com/D156940
This adds `count` out parameter for recursive file remove calls to report the number of the removed entries.
Having a lot of files removed by `::Remove(recursive=true)` has been a problem, as a slow disk can cause a hang with such call. A counter feature will help us knowing the situation better via telemetry.
The use of out parameter here is to mark it optional and prevent unwanted changes in existing callers (because a return value can't be optional).
Differential Revision: https://phabricator.services.mozilla.com/D156940