Closed Bug 1114398 Opened 6 years ago Closed 6 years ago

SVG can mix up Paths with wrong DrawTarget types

Categories

(Core :: SVG, defect)

x86_64
Windows 8.1
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla37

People

(Reporter: bas.schouten, Assigned: bas.schouten)

Details

Attachments

(2 files)

SVG can use cached paths that were created for a different DT backend than is currently being requested.
This patch will allow us to match D2D paths through dt->GetBackendType() == path->GetBackendType().

In theory we don't need this restriction, but not having it will only hide bugs with D2D/D2D1.1 mismatches. Realistically a path should just always be used with the backend type it's created for.
Attachment #8539881 - Flags: review?(jmuizelaar)
Attachment #8539881 - Attachment description: Make Direct2D paths specifically typed to a backend type → Part 1: Make Direct2D paths specifically typed to a backend type
Comment on attachment 8539881 [details] [diff] [review]
Part 1: Make Direct2D paths specifically typed to a backend type

Review of attachment 8539881 [details] [diff] [review]:
-----------------------------------------------------------------

Does this interact with the Canvas path stuff when the path was created for a different backend then it is being used on?
Attachment #8539881 - Flags: review?(jmuizelaar) → review+
(In reply to Jeff Muizelaar [:jrmuizel] from comment #3)
> Comment on attachment 8539881 [details] [diff] [review]
> Part 1: Make Direct2D paths specifically typed to a backend type
> 
> Review of attachment 8539881 [details] [diff] [review]:
> -----------------------------------------------------------------
> 
> Does this interact with the Canvas path stuff when the path was created for
> a different backend then it is being used on?

In theory it shouldn't because this sort of mix-up simply shouldn't occur.
Attachment #8539882 - Flags: review?(jwatt) → review+
https://hg.mozilla.org/mozilla-central/rev/8309d6ce7a38
https://hg.mozilla.org/mozilla-central/rev/d5ead6673b95
Status: ASSIGNED → RESOLVED
Closed: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla37
You need to log in before you can comment on or make changes to this bug.