Closed Bug 1223740 Opened 5 years ago Closed 4 years ago

[Skia] SkToS16: failed assertion "(int16_t)x == x"

Categories

(Core :: Graphics, defect)

defect
Not set

Tracking

()

RESOLVED FIXED
mozilla45
Tracking Status
firefox45 --- fixed

People

(Reporter: jruderman, Assigned: lsalzman)

References

(Blocks 1 open bug)

Details

(Keywords: assertion, testcase)

Attachments

(3 files)

Attached file testcase
gfx/skia/skia/src/core/SkDebug.cpp:25: failed assertion "(int16_t)x == x"

(I can't reproduce bug 906052 or bug 747302 on this computer.)
Attached file stack
Assignee: nobody → lsalzman
Skia is assuming without checking that surface sizes can fit into a 16 bit signed integer. We're allocating really large temporary draw targets for rendering the shadow which overflow this. This triggers the assertion.

This patch makes sure we don't create anything so large as to do that.
Attachment #8689641 - Flags: review?(bas)
Status: NEW → ASSIGNED
Attachment #8689641 - Flags: review?(bas) → review+
https://hg.mozilla.org/mozilla-central/rev/a9689a6d6756
Status: ASSIGNED → RESOLVED
Closed: 4 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla45
Depends on: 1228188
You need to log in before you can comment on or make changes to this bug.