Closed
Bug 712649
Opened 12 years ago
Closed 12 years ago
Components.utils.getWeakReference(null) should fail silently (as it used to do)
Categories
(Core :: XPConnect, defect)
Tracking
()
VERIFIED
FIXED
mozilla12
Tracking | Status | |
---|---|---|
firefox8 | --- | unaffected |
firefox9 | --- | unaffected |
firefox10 | --- | unaffected |
firefox11 | + | verified |
firefox12 | --- | verified |
People
(Reporter: ma1, Assigned: Ms2ger)
References
Details
(Keywords: addon-compat, dev-doc-complete, Whiteboard: [qa!] [testday-20120203])
Attachments
(1 file)
1.88 KB,
patch
|
bholley
:
review+
akeybl
:
approval-mozilla-aurora+
|
Details | Diff | Splinter Review |
In 11 and above Components.utils.getWeakReference(null) throws NS_ERROR_FAILURE. It used to fail silently instead, so it's probably breaking some clients (NoScript, for instance). Also, since the value held by a weak reference will eventually be null anyway, allowing clients pass null may be seen as more consistent.
Assignee | ||
Comment 1•12 years ago
|
||
I think it makes sense to allow this, but we should probably keep propagating other exceptions.
Attachment #583499 -
Flags: review?(bobbyholley+bmo)
Assignee | ||
Updated•12 years ago
|
Assignee: nobody → Ms2ger
Target Milestone: --- → mozilla11
Comment 2•12 years ago
|
||
Comment on attachment 583499 [details] [diff] [review] Components.utils.getWeakReference(null) should fail silently; Looks good. r=bholley We should get this in for 11 too, otherwise it sounds like we'll break extensions.
Attachment #583499 -
Flags: review?(bobbyholley+bmo) → review+
Updated•12 years ago
|
status-firefox10:
--- → unaffected
status-firefox11:
--- → affected
status-firefox12:
--- → affected
status-firefox8:
--- → unaffected
status-firefox9:
--- → unaffected
tracking-firefox11:
--- → ?
Updated•12 years ago
|
Target Milestone: mozilla11 → ---
Version: Trunk → 11 Branch
Assignee | ||
Comment 3•12 years ago
|
||
https://hg.mozilla.org/mozilla-central/rev/834bfdd83f70
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla12
Assignee | ||
Comment 4•12 years ago
|
||
Comment on attachment 583499 [details] [diff] [review] Components.utils.getWeakReference(null) should fail silently; This is a regression from bug 708330, which broke NoScript. The patch should be safe.
Attachment #583499 -
Flags: approval-mozilla-aurora?
Assignee | ||
Updated•12 years ago
|
Keywords: dev-doc-needed
Comment 5•12 years ago
|
||
Comment on attachment 583499 [details] [diff] [review] Components.utils.getWeakReference(null) should fail silently; [Triage Comment] Approved for Aurora given the risk of regressing add-ons.
Attachment #583499 -
Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
Updated•12 years ago
|
Keywords: addon-compat
Assignee | ||
Comment 6•12 years ago
|
||
https://hg.mozilla.org/releases/mozilla-aurora/rev/bf34343622f4
Updated•12 years ago
|
Is there something QA can do to verify this fix? possibly involving NoScript?
Whiteboard: [qa?]
Assignee | ||
Comment 8•12 years ago
|
||
I believe NoScript already works around this bug.
Reporter | ||
Comment 9•12 years ago
|
||
(In reply to Ms2ger from comment #8) > I believe NoScript already works around this bug. Yes it does. You can verify by running the following in the Error Console or in a chrome-scoped scratchpad: try { alert("OK (" + Components.utils.getWeakReference(null) + ")") } catch(e) { alert("FAIL") }
Comment 10•12 years ago
|
||
Mozilla/5.0 (Windows NT 5.1; rv:11.0) Gecko/20100101 Firefox/11.0 Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:11.0) Gecko/20100101 Firefox/11.0 Mozilla/5.0 (X11; Linux x86_64; rv:11.0) Gecko/20100101 Firefox/11.0 Verified using guideline in comment 9 on Ubuntu 11.10, Mac OS 10.6, Windows XP (Firefox 11 beta 1). No failures. All resulted in the following message in the Error Console: "OK ([xpconnect wrapped xpcIJSWeakReference])"
Whiteboard: [qa+] → [qa+] [testday-20120203] [qa!:11]
Comment 11•12 years ago
|
||
Mozilla/5.0 (X11; Linux i686; rv:12.0) Gecko/20100101 Firefox/12.0 Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:12.0) Gecko/20100101 Firefox/12.0 Mozilla/5.0 (Windows NT 6.1; WOW64; rv:12.0) Gecko/20100101 Firefox/12.0 Marking verified after checking on Firefox 12 beta 3 with the same guidelines from comment 9. Result: "OK ([xpconnect wrapped xpcIJSWeakReference])"
Status: RESOLVED → VERIFIED
Whiteboard: [qa+] [testday-20120203] [qa!:11] → [qa!] [testday-20120203]
Comment 12•12 years ago
|
||
Documentation updated: https://developer.mozilla.org/en/Components.utils.getWeakReference Listed on Firefox 12 for developers.
Keywords: dev-doc-needed → dev-doc-complete
You need to log in
before you can comment on or make changes to this bug.
Description
•