Closed Bug 1074974 Opened 10 years ago Closed 10 years ago

Make HelpersD2D.h's CreateStrokeStyleForOptions more robust

Categories

(Core :: Graphics, defect)

x86
Windows 8.1
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla35

People

(Reporter: jwatt, Assigned: jwatt)

Details

Attachments

(1 file)

I'm seeing Windows 7/8 failure of layout/reftests/svg/stroke-dasharray-01.svg with some of my patches. It turns out this is because if you pass a StrokeOptions argument to HelpersD2D.h's CreateStrokeStyleForOptions function where the object has mDashLength set to zero, then CreateStrokeStyleForOptions will still try to go ahead and create a dash pattern if mDashPattern is set. This results in the stroke failing to paint.

Perhaps CreateStrokeStyleForOptions should check mDashLength in addition to checking whether mDashPattern is null. If that's not acceptable, than at the very least it should assert.
Attached patch patchSplinter Review
Attachment #8497623 - Flags: review?(bas)
Attachment #8497623 - Flags: review?(bas) → review+
https://hg.mozilla.org/mozilla-central/rev/54fe4cbba069
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla35
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: