Closed
Bug 886230
Opened 11 years ago
Closed 11 years ago
Assertion failure: "should have already reflowed the kid" with DRAWWINDOW_DO_NOT_FLUSH
Categories
(Core :: SVG, defect)
Tracking
()
RESOLVED
FIXED
mozilla25
People
(Reporter: jruderman, Assigned: heycam)
References
Details
(Keywords: assertion, testcase)
Attachments
(3 files)
1. Install https://www.squarefree.com/extensions/domFuzzLite3.xpi
2. Set
user_pref("svg.text.css-frames.enabled", true);
3. Load the testcase
Assertion failure: !(((kid)->GetStateBits() & ((nsFrameState(1) << (10)) | (nsFrameState(1) << (12)))) != 0) (should have already reflowed the kid), at layout/svg/nsSVGTextFrame2.cpp:4837
This assertion was added in bug 885642.
DRAWWINDOW_DO_NOT_FLUSH is used by Firefox's thumbnail service, IIRC. So there's probably a way to trigger this bug without the extension.
Reporter | ||
Comment 1•11 years ago
|
||
Assignee | ||
Comment 2•11 years ago
|
||
I think the best we can do is just not paint the text, which is what we are doing now (but also asserting). It'd be good to keep the assertion in there for other cases where we know we should have reflowed the text. I wonder if there's a way to detect that we're in a DRAWWINDOW_DO_NOT_FLUSH?
Assignee | ||
Comment 3•11 years ago
|
||
roc, would it be OK to store a bit (only #ifdef DEBUG) in PresShell::mRenderFlags while we are painting the window under DrawWindow(..., DRAWWINDOW_DO_NOT_FLUSH) that nsSVGTextFrame2::PaintSVG could then check to see whether it can skip the assertion that the text frames are not dirty?
Or otherwise, have a flag on the nsDisplayListBuilder that nsDisplaySVGText::Paint can look at?
Flags: needinfo?(roc)
(In reply to Cameron McCormack (:heycam) from comment #3)
> roc, would it be OK to store a bit (only #ifdef DEBUG) in
> PresShell::mRenderFlags while we are painting the window under
> DrawWindow(..., DRAWWINDOW_DO_NOT_FLUSH) that nsSVGTextFrame2::PaintSVG
> could then check to see whether it can skip the assertion that the text
> frames are not dirty?
Yes I think that's reasonable.
Flags: needinfo?(roc)
Assignee | ||
Comment 5•11 years ago
|
||
I wasn't sure that it was really worth the clutter of wrapping things in #ifdefs in the end.
Assignee | ||
Comment 6•11 years ago
|
||
Green try run: https://tbpl.mozilla.org/?tree=Try&rev=d9eb13626402
Comment on attachment 767027 [details] [diff] [review]
patch
Review of attachment 767027 [details] [diff] [review]:
-----------------------------------------------------------------
::: testing/specialpowers/content/specialpowersAPI.js
@@ +1134,5 @@
> + flags |= ctx.DRAWWINDOW_DRAW_CARET;
> + }
> + if (options.DRAWWINDOW_DO_NOT_FLUSH) {
> + flags |= ctx.DRAWWINDOW_DO_NOT_FLUSH;
> + }
I think you can write something like
for (var option in options) {
flags |= ctx[option];
}
Hooray Javascript!
Attachment #767027 -
Flags: review?(roc) → review+
Assignee | ||
Comment 8•11 years ago
|
||
(In reply to Robert O'Callahan (:roc) (Mozilla Corporation) from comment #7)
> I think you can write something like
> for (var option in options) {
> flags |= ctx[option];
> }
> Hooray Javascript!
Good one. :)
https://hg.mozilla.org/integration/mozilla-inbound/rev/d7c237784ce9
Comment 9•11 years ago
|
||
Backed out for B2G mochitest-9 failures in test_bug582181-1.html:
https://tbpl.mozilla.org/?tree=Mozilla-Inbound&fromchange=727736b233b3&tochange=7e06e9a0a8d9&rev=d7c237784ce9&jobname=mochitest-9
Also intermittently on OS X:
https://tbpl.mozilla.org/php/getParsedLog.php?id=24563041&tree=Mozilla-Inbound
remote: https://hg.mozilla.org/integration/mozilla-inbound/rev/4441fe8e2ead
Assignee | ||
Comment 10•11 years ago
|
||
https://hg.mozilla.org/integration/mozilla-inbound/rev/c965b82024eb
I had to do:
for (var option in options) {
flags |= options[option] && ctx[option];
}
to make { DRAWWINDOW_DO_NOT_FLUSH: false } not set that flag.
Comment 11•11 years ago
|
||
Status: ASSIGNED → RESOLVED
Closed: 11 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla25
You need to log in
before you can comment on or make changes to this bug.
Description
•