"ABORT: Unexpected SVG paint type" with transition for -moz-objectStroke

RESOLVED FIXED in mozilla20

Status

()

defect
--
critical
RESOLVED FIXED
7 years ago
7 years ago

People

(Reporter: jruderman, Assigned: eflores)

Tracking

(Blocks 1 bug, {assertion, testcase})

Trunk
mozilla20
x86_64
macOS
Points:
---
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(3 attachments, 1 obsolete attachment)

(Reporter)

Description

7 years ago
Posted file testcase
###!!! ABORT: Unexpected SVG paint type: 'paint.mType == eStyleSVGPaintType_None', file layout/style/nsStyleAnimation.cpp, line 3113

This stroke value was just added, in bug 719286.
(Reporter)

Comment 1

7 years ago
Posted file stack trace
Assignee: nobody → eflores
Status: NEW → RESOLVED
Last Resolved: 7 years ago
Resolution: --- → DUPLICATE
Duplicate of bug: 790072
Status: RESOLVED → REOPENED
Resolution: DUPLICATE → ---
Posted patch Fix (obsolete) — Splinter Review
Fixed and added simple crashtest for now.

Test for actual functionality to come when we have support for animations in SVG glyphs.
Attachment #663929 - Flags: review?(dbaron)
Posted patch FixSplinter Review
Forgot to add actual crashtest.
Attachment #663929 - Attachment is obsolete: true
Attachment #663929 - Flags: review?(dbaron)
Attachment #663930 - Flags: review?(dbaron)
Comment on attachment 663930 [details] [diff] [review]
Fix

I think it would be better to treat the computed value of -moz-ObjectFill and -moz-ObjectStroke as a color (both here and for 'inherit').  But I'm ok with this for now.

However, if you take this approach, you need to make nsStyleAnimation::AddWeighted not abort when it tries to interpolate between two such results (say, from -moz-ObjectFill to -moz-ObjectStroke), which it does right now, since you don't hit this:

      if (unit[0] == eCSSUnit_Null || unit[1] == eCSSUnit_Null ||
          unit[0] == eCSSUnit_URL) {
        return false;
      }

and then you hit this:

        if (!AddCSSValuePixelPercentCalc(restrictions, unit[i],
                                         aCoeff1, pair1->*member,
                                         aCoeff2, pair2->*member,
                                         result->*member) ) {
          NS_ABORT_IF_FALSE(false, "unexpected unit");
          return false;
        }

So at a minimum, you need to extend that first check for unit[0] being eCSSUnit_URL to also check for eCSSUnit_Enumerated.  r=dbaron if you add that, I guess.
Attachment #663930 - Flags: review?(dbaron) → review+
... and also make the same change in nsStyleAnimation::ComputeDistance
https://hg.mozilla.org/mozilla-central/rev/9160d646fa8b
Status: REOPENED → RESOLVED
Last Resolved: 7 years ago7 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla20
You need to log in before you can comment on or make changes to this bug.