Closed
Bug 1943262
Opened 11 months ago
Closed 11 months ago
Refactor instantiation of nsEffectiveTLDService
Categories
(Core :: Networking: DNS, enhancement, P2)
Core
Networking: DNS
Tracking
()
RESOLVED
FIXED
136 Branch
| Tracking | Status | |
|---|---|---|
| firefox136 | --- | fixed |
People
(Reporter: leplatrem, Assigned: valentin)
References
Details
(Whiteboard: [necko-triaged])
Attachments
(1 file)
In Bug 1786310 we added a safety check around the service destructor.
The service gets instantiated and destroyed in different places, and as Valentin pointed out in https://bugzilla.mozilla.org/show_bug.cgi?id=1786310#c16
The component definition is marked as singletong but refers the constructor - which definitely won't return the same object for every call.
'singleton': True,
'type': 'nsEffectiveTLDService',
'headers': ['/netwerk/dns/nsEffectiveTLDService.h'],
'init_method': 'Init',
There seems to be some possible improvements and clean-up around the instantiation of this service.
| Assignee | ||
Comment 1•11 months ago
|
||
This ensures that the instantiation of the service always returns the
same singleton. I also changed calls to nsEffectiveTLDService::GetInstance
to use mozilla::components::EffectiveTLD::Service() instead.
Updated•11 months ago
|
Assignee: nobody → valentin.gosu
Status: NEW → ASSIGNED
| Assignee | ||
Updated•11 months ago
|
Severity: -- → S3
Priority: -- → P2
Whiteboard: [necko-triaged]
Pushed by valentin.gosu@gmail.com:
https://hg.mozilla.org/integration/autoland/rev/b233889facbe
Refactor instantiation of nsEffectiveTLDService r=cookie-reviewers,anti-tracking-reviewers,permissions-reviewers,emz
Comment 3•11 months ago
|
||
| bugherder | ||
Status: ASSIGNED → RESOLVED
Closed: 11 months ago
status-firefox136:
--- → fixed
Resolution: --- → FIXED
Target Milestone: --- → 136 Branch
You need to log in
before you can comment on or make changes to this bug.
Description
•