Closed
Bug 114220
Opened 23 years ago
Closed 23 years ago
text control frames get readded to primary frame map during destruction
Categories
(Core :: Layout: Form Controls, defect, P1)
Core
Layout: Form Controls
Tracking
()
RESOLVED
FIXED
mozilla0.9.7
People
(Reporter: dbaron, Assigned: dbaron)
References
Details
Attachments
(1 file)
9.62 KB,
patch
|
john
:
review+
jst
:
superreview+
|
Details | Diff | Splinter Review |
Text control frames get readded to the primary frame map during their
destruction in some cases, after they've been removed. This can lead to stale
frames (the text control frame, and up its ancestor chain) being in the map.
See attachment 59623 [details] on bug 105619 for a testcase and bug 105619 comment 57 for
a stack.
I'll attach a patch that prevents this from happening by passing the frame from
frame to content in some cases, as jst suggested.
Assignee | ||
Updated•23 years ago
|
Status: NEW → ASSIGNED
Priority: -- → P1
Target Milestone: --- → mozilla0.9.7
Assignee | ||
Comment 1•23 years ago
|
||
Assignee | ||
Comment 2•23 years ago
|
||
The change in nsFrameManager.cpp needs to check for non-null ops, i.e.:
#ifdef DEBUG
if (mPrimaryFrameMap.ops) {
nsCOMPtr<nsIContent> content;
aFrame->GetContent(getter_AddRefs(content));
PrimaryFrameMapEntry *entry = NS_STATIC_CAST(PrimaryFrameMapEntry*,
PL_DHashTableOperate(&mPrimaryFrameMap, content, PL_DHASH_LOOKUP));
NS_ASSERTION(!PL_DHASH_ENTRY_IS_BUSY(entry) || entry->frame != aFrame,
"frame was not removed from primary frame map before"
"destruction or was readded to map after being removed");
}
#endif
Updated•23 years ago
|
Attachment #60945 -
Flags: superreview+
Comment 3•23 years ago
|
||
Comment on attachment 60945 [details] [diff] [review]
patch
sr=jst, but please also make nsIGfxTextControlFrame use
NS_DEFINE_STATIC_IID_ACCESSOR() for defining the IID accessor.
Comment 4•23 years ago
|
||
Comment on attachment 60945 [details] [diff] [review]
patch
r=jkeiser
Attachment #60945 -
Flags: review+
dbaron landed the fix on 12/10/2001 21:39
Status: ASSIGNED → RESOLVED
Closed: 23 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 6•23 years ago
|
||
This may have also fixed bug 108704.
Assignee | ||
Comment 7•23 years ago
|
||
Oh, and the fact that I forgot to check in my comment #2 caused bug 114675, but
was easily fixed.
Assignee | ||
Comment 8•23 years ago
|
||
*** Bug 108704 has been marked as a duplicate of this bug. ***
Updated•23 years ago
|
QA Contact: madhur → tpreston
You need to log in
before you can comment on or make changes to this bug.
Description
•