From ebd6dea009479e612c67d78416b8680bb23dba94 Mon Sep 17 00:00:00 2001 From: Chris Wilson Date: Mon, 4 Jun 2012 11:56:11 +0100 Subject: uxa/dri: Make sure is_glamor_pixmap is always initialised The code paths are too twisty to be sure otherwise. Reported-by: Zdenek Kabelac Signed-off-by: Chris Wilson --- src/intel_dri.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/intel_dri.c b/src/intel_dri.c index 389ecdd9..a1778159 100644 --- a/src/intel_dri.c +++ b/src/intel_dri.c @@ -263,7 +263,7 @@ I830DRI2CreateBuffers(DrawablePtr drawable, unsigned int *attachments, DRI2BufferPtr buffers; I830DRI2BufferPrivatePtr privates; PixmapPtr pixmap, pDepthPixmap; - int is_glamor_pixmap = FALSE; + bool is_glamor_pixmap = false; int i; buffers = calloc(count, sizeof *buffers); @@ -282,7 +282,7 @@ I830DRI2CreateBuffers(DrawablePtr drawable, unsigned int *attachments, pixmap = get_front_buffer(drawable); if (pixmap && intel_get_pixmap_private(pixmap) == NULL) { - is_glamor_pixmap = TRUE; + is_glamor_pixmap = true; drawable = &pixmap->drawable; pixmap = NULL; } @@ -390,7 +390,7 @@ I830DRI2CreateBuffer(DrawablePtr drawable, unsigned int attachment, DRI2Buffer2Ptr buffer; I830DRI2BufferPrivatePtr privates; PixmapPtr pixmap; - int is_glamor_pixmap; + bool is_glamor_pixmap = false; buffer = calloc(1, sizeof *buffer); if (buffer == NULL) @@ -406,7 +406,7 @@ I830DRI2CreateBuffer(DrawablePtr drawable, unsigned int attachment, pixmap = get_front_buffer(drawable); if (pixmap && intel_get_pixmap_private(pixmap) == NULL) { - is_glamor_pixmap = TRUE; + is_glamor_pixmap = true; drawable = &pixmap->drawable; pixmap = NULL; } -- cgit v1.2.3