-
Committer:
Bryce Harrington
-
Author(s):
Massimo
-
Date:
2018-03-08 21:30:17 UTC
-
Revision ID:
git-v1:5454b85d4bf2f7bea454c940d90255a15517fa3b
bfo#91271 - Fix access of uninitialized memory
Valgrind reports that xlib-render-compositor's composite_traps()
accesses uninitialized memory when traps->num_traps == 0.
This happens in the line that says
if (xtraps[0].left.p1.y < xtraps[0].left.p2.y) {
after the 'for' loop. We can actually return early if there are no
trapezoids to render.
Fixes: https://bugs.freedesktop.org/show_bug.cgi?id=91271
Reviewed-by: Bryce Harrington <bryce@osg.samsung.com>