[PATCH] render: Avoid infinite loops in alpha map handling (#23581)
Keith Packard
keithp at keithp.com
Wed May 12 14:49:25 PDT 2010
On 12 May 2010 20:27:11 +0200, Soeren Sandmann <sandmann at daimi.au.dk> wrote:
> The alphaMap structure gets mirrored in pixman images, and it does
> recurse through its alpha_map pointer:
Can you make it stop?
> in which I suggest to simply BadMatch out if you try to set a picture
> as its own alpha map or set an alpha map that already have an alpha
> map.
Setting a picture as its own alpha map seems well defined (the same as
None). The problem with the other case is that you can *later on* change
the picture used as an alpha map to add an alpha map there.
> The protocol should possibly also say that you get unpredictable
> rendering if a picture and its alpha map point to the same underlying
> drawable. (I don't think pixman will crash in that case, and
> acceleration code ignores alpha maps generally).
Yeah, just making the self-referential case the same as None should fix
that. I don't know how to fix the other case except by having the
rendering code not recurse.
--
keith.packard at intel.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: not available
URL: <http://lists.x.org/archives/xorg-devel/attachments/20100512/1dc65e23/attachment-0001.pgp>
More information about the xorg-devel
mailing list