diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2013-01-29 03:52:02 +0000 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2013-01-29 03:52:02 +0000 |
commit | 41ae904461e344fbfa3be3d276a7102bb4304b19 (patch) | |
tree | c1337f98f18209bc69f317dceca6963e17f95cf7 | |
parent | 9b92625151ca75a6ee10f231f83b53f67a371947 (diff) |
xlib/shm: Appease the compiler for a 'maybe used uninitialised' variable
Initialise shm during its declaration so that it is indeed initialised
for the cleanup after every path.
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
-rw-r--r-- | src/cairo-xlib-render-compositor.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/cairo-xlib-render-compositor.c b/src/cairo-xlib-render-compositor.c index e3ea3f00..12f357de 100644 --- a/src/cairo-xlib-render-compositor.c +++ b/src/cairo-xlib-render-compositor.c @@ -246,7 +246,7 @@ draw_image_boxes (void *_dst, { cairo_xlib_surface_t *dst = _dst; struct _cairo_boxes_chunk *chunk; - cairo_image_surface_t *shm; + cairo_image_surface_t *shm = NULL; cairo_int_status_t status; int i; @@ -260,7 +260,6 @@ draw_image_boxes (void *_dst, goto draw_image_boxes; } - shm = NULL; if (boxes_cover_surface (boxes, dst)) shm = (cairo_image_surface_t *) _cairo_xlib_surface_get_shm (dst, TRUE); if (shm) { |