Closed
Bug 1929190
Opened 1 year ago
Closed 1 year ago
QM: Temporary origin is not initialized if a previous initialization attempt failed
Categories
(Core :: Storage: Quota Manager, defect, P1)
Core
Storage: Quota Manager
Tracking
()
RESOLVED
FIXED
134 Branch
People
(Reporter: janv, Assigned: janv)
References
(Blocks 1 open bug)
Details
Attachments
(3 files)
QM_TRY_INSPECT(const bool& created, EnsureOriginDirectory(*directory));
if (created) {
const int64_t timestamp = PR_Now();
FullOriginMetadata fullOriginMetadata =
FullOriginMetadata{aOriginMetadata,
/* aPersisted */ false, timestamp};
AddTemporaryOrigin(fullOriginMetadata);
// Only creating .metadata-v2 to reduce IO.
QM_TRY(MOZ_TO_RESULT(CreateDirectoryMetadata2(*directory, timestamp,
/* aPersisted */ false,
aOriginMetadata)));
// Don't need to traverse the directory, since it's empty.
InitQuotaForOrigin(fullOriginMetadata, ClientUsageArray(),
/* aUsageBytes */ 0);
}
The case when the origin directory already exists (created by a previous failed initialization) needs to be handled.
| Assignee | ||
Comment 1•1 year ago
|
||
| Assignee | ||
Comment 2•1 year ago
|
||
| Assignee | ||
Updated•1 year ago
|
Priority: P2 → P1
| Assignee | ||
Comment 3•1 year ago
|
||
Pushed by jvarga@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/e402a74f82c7
QM: Modify test_initializeTemporaryOrigin_failure.js to allow running multiple subtests; r=dom-storage-reviewers,asuth
https://hg.mozilla.org/integration/autoland/rev/b7fdcfd96d84
QM: Add a disabled subtest for a failure during temporary origin initialization; r=dom-storage-reviewers,asuth
https://hg.mozilla.org/integration/autoland/rev/6c85fec070ed
QM: Initialize temporary origin even if a previous initialization attempt failed; r=dom-storage-reviewers,asuth
Comment 5•1 year ago
|
||
| bugherder | ||
https://hg.mozilla.org/mozilla-central/rev/e402a74f82c7
https://hg.mozilla.org/mozilla-central/rev/b7fdcfd96d84
https://hg.mozilla.org/mozilla-central/rev/6c85fec070ed
Status: ASSIGNED → RESOLVED
Closed: 1 year ago
status-firefox134:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 134 Branch
| Assignee | ||
Updated•1 year ago
|
Crash Signature: [@ mozilla::dom::quota::OriginInfo::LockedAccessTime ]
| Assignee | ||
Comment 6•1 year ago
|
||
Comment on attachment 9436859 [details]
Bug 1929190 - QM: Initialize temporary origin even if a previous initialization attempt failed; r=#dom-storage
Beta/Release Uplift Approval Request
- User impact if declined/Reason for urgency: Theses patches are meant to fix a top crash
- Is this code covered by automated tests?: Yes
- Has the fix been verified in Nightly?: Yes
- Needs manual test from QE?: No
- If yes, steps to reproduce:
- List of other uplifts needed: Bug 1927723 and bug 1928092 (patches for all 3 bugs D227198 - D228670 need to land together, 10 patches in total)
- Risk to taking this patch: Low
- Why is the change risky/not risky? (and alternatives if risky): I think the risk is rather low despite the number of patches. Most of them are just about providing new testing infrastructure and new tests.
- String changes made/needed: None
- Is Android affected?: Yes
Attachment #9436859 -
Flags: approval-mozilla-beta?
Comment 7•1 year ago
|
||
Comment on attachment 9436859 [details]
Bug 1929190 - QM: Initialize temporary origin even if a previous initialization attempt failed; r=#dom-storage
Approved for 133.0b9
Attachment #9436859 -
Flags: approval-mozilla-beta? → approval-mozilla-beta+
Updated•1 year ago
|
status-firefox133:
--- → fixed
| Assignee | ||
Updated•1 year ago
|
Crash Signature: [@ mozilla::dom::quota::OriginInfo::LockedAccessTime ]
You need to log in
before you can comment on or make changes to this bug.
Description
•