[PATCH weston 08/11] compositor: ignore surface_damage with negative height or width
Derek Foreman
derekf at osg.samsung.com
Thu Nov 26 07:34:21 PST 2015
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
On 26/11/15 07:21 AM, Pekka Paalanen wrote:
> On Thu, 19 Nov 2015 11:15:38 -0600 Derek Foreman
> <derekf at osg.samsung.com> wrote:
>
>> On 18/11/15 07:33 PM, Bill Spitzak wrote:
>>>
>>>
>>> On Wed, Nov 18, 2015 at 2:32 PM, Derek Foreman
>>> <derekf at osg.samsung.com <mailto:derekf at osg.samsung.com>>
>>> wrote:
>>>
>>> If we pass negative height or width on to pixman we get error
>>> messages in the log.
>>>
>>> Signed-off-by: Derek Foreman <derekf at osg.samsung.com
>>> <mailto:derekf at osg.samsung.com>> --- src/compositor.c | 3 +++
>>> 1 file changed, 3 insertions(+)
>>>
>>> diff --git a/src/compositor.c b/src/compositor.c index
>>> 666bc15..0efb325 100644 --- a/src/compositor.c +++
>>> b/src/compositor.c @@ -2574,6 +2574,9 @@ surface_damage(struct
>>> wl_client *client, { struct weston_surface *surface =
>>> wl_resource_get_user_data(resource);
>>>
>>> + if (width < 0 || height < 0) + return;
>>>
>>>
>>> Might as well quit on <= 0 here, since a zero-sized rectangle
>>> won't do anything.
>>
>> Fair point, I've made the change locally. When I've accumulated
>> enough feedback to make a v2 worthwhile it'll be there.
>
> Yup, you can stamp a Reviewed-by: Pekka Paalanen
> <pekka.paalanen at collabora.co.uk> on this one with <= 0.
>
> And push for all I care. :-)
I've done just that, thanks. :)
> Thanks, pq
>
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1
iQEcBAEBAgAGBQJWVyZ9AAoJEF5USY5pfxHXiqMH/R+N7AIm/SqRjdb8CQIOF2Z9
gjrLLJA5RfhK1XdS737j4AeZ+AgB9kN/FxA4ziN27FRmoKrq1Hyv/xUkppeiNun4
Wf2Yy35iENqAr93Sai5eLRHc7GF/IsJhC53/cEh+DUdfwzsCDNct71TR+Iy5yUxP
qEszLkzYMfh4E0XXljYWSUgbZB0a3qgJH6TeOAucA7RWva0OeRQJkEWmU9MY0Uwa
pqpg/cysRLhUYT0ySlQgwAWN1n8TYZx46yTR7Oa7Y3k3SzLY/inq2aYNNY3p+Yro
r5cAu9aNUCyCJZd9czUtiFI0h8pZAg4MXGJoZYq2LdSbGLbFWG1tFPcINkPkAjE=
=vn+g
-----END PGP SIGNATURE-----
More information about the wayland-devel
mailing list