Closed
Bug 334430
Opened 19 years ago
Closed 19 years ago
[FIX]nsXBLService::LoadBindings causes reentry into frame construction
Categories
(Core :: XBL, defect, P1)
Core
XBL
Tracking
()
RESOLVED
FIXED
mozilla1.9alpha1
People
(Reporter: dbaron, Assigned: bzbarsky)
References
Details
Attachments
(2 files, 1 obsolete file)
8.90 KB,
text/plain; charset=utf-8
|
Details | |
2.40 KB,
patch
|
sicking
:
review+
sicking
:
superreview+
|
Details | Diff | Splinter Review |
nsXBLService::LoadBindings, called from ConstructFrameInternal (which can be arbitrarily deep within a frame construction entry point, unlike the calls to ProcessAttachedQueue which are always made from the entry point), sometimes causes reentry into frame construction. Because of this, I had to make one of the assertions added for bug 310985 a warning instead.
Stack coming shortly.
Reporter | ||
Comment 1•19 years ago
|
||
Reporter | ||
Comment 2•19 years ago
|
||
Comment on attachment 218792 [details]
stack of first assertion opening Firefox options dialog
Oops, sorry, that stack was actually a different bug; I didn't look closely enough.
Attachment #218792 -
Attachment is obsolete: true
Reporter | ||
Comment 3•19 years ago
|
||
Assignee | ||
Comment 5•19 years ago
|
||
So why are we passing PR_TRUE for aNotify here? I'd think we want to pass PR_FALSE. I'm looking, in particular, at:
textContent->SetText(value, PR_TRUE);
realElement->AppendChildTo(textContent, PR_TRUE);
This looks like it's handling xbl:inherits="xbl:text=foo" and xbl:inherits="value=foo" (the latter only for <xul:html> nodes).
Is there something we should test to make sure it doesn't break if we're going to twiddle this code?
Severity: critical → normal
Comment 6•19 years ago
|
||
I think checkboxes and radiobuttons use xbl:text=label although offhand I don't know of an example of changing a checkbox or radio button label.
Out of interest, whose job would it be to create the frame(s) for the new text?
Assignee | ||
Comment 7•19 years ago
|
||
The frame constructor's. Changing is a different thing; we're lookin at nsXBLPrototypeBinding::SetInitialAttributes here. There are no frames anywhere in sight for this stuff.
I think we should forbid nsIDocumentObservers to cause mutations to the DOM since that can cause a whole set of issues similar to the ones we have with mutation events.
A simple solution would be to wait until EndUpdate is called (enough times) and then perform the mutation.
Assignee | ||
Comment 9•19 years ago
|
||
That's a separate issue from this bug. But yeah, that would be nice....
Assignee | ||
Comment 10•19 years ago
|
||
Assignee: general → bzbarsky
Status: NEW → ASSIGNED
Attachment #218893 -
Flags: superreview?(bugmail)
Attachment #218893 -
Flags: review?(bugmail)
Assignee | ||
Updated•19 years ago
|
Priority: -- → P1
Summary: nsXBLService::LoadBindings causes reentry into frame construction → [FIX]nsXBLService::LoadBindings causes reentry into frame construction
Target Milestone: --- → mozilla1.9alpha
So don't we want to use PR_TRUE there? To get layout to update.
Assignee | ||
Comment 12•19 years ago
|
||
What layout? This is just-installed anonymous content for a binding we're still setting up. There is no layout.
We do use PR_TRUE in AttributeChanged, and we should file a separate bug on making that not suck.
Comment on attachment 218893 [details] [diff] [review]
Proposed patch
ah, ok. r/sr=sicking
Attachment #218893 -
Flags: superreview?(bugmail)
Attachment #218893 -
Flags: superreview+
Attachment #218893 -
Flags: review?(bugmail)
Attachment #218893 -
Flags: review+
Assignee | ||
Comment 14•19 years ago
|
||
Fixed.
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
You need to log in
before you can comment on or make changes to this bug.
Description
•