summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRami Ylimäki <rami.ylimaki@vincit.fi>2011-12-18 18:29:38 +0200
committerKeith Packard <keithp@keithp.com>2011-12-19 22:30:11 -0800
commit603fcb3abf155e91fd3250f4a7aa16f289506e8e (patch)
tree9fad6936888388e18630753eb621f20d16d57d06
parent3aca8199405cff5097ee5813605ec78b5ae44a43 (diff)
dri2: Initialize needInvalidate member of DRI2Drawable.
If the client is not behaving correctly and swaps buffers before getting them, Valgrind will complain about uninitialized memory being used in DRI2InvalidateDrawable. Signed-off-by: Rami Ylimäki <rami.ylimaki@vincit.fi> Reviewed-by: Ville Syrjälä <syrjala@sci.fi> Signed-off-by: Keith Packard <keithp@keithp.com>
-rw-r--r--hw/xfree86/dri2/dri2.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/hw/xfree86/dri2/dri2.c b/hw/xfree86/dri2/dri2.c
index 0d613be8e..d2035a4e6 100644
--- a/hw/xfree86/dri2/dri2.c
+++ b/hw/xfree86/dri2/dri2.c
@@ -181,6 +181,7 @@ DRI2AllocateDrawable(DrawablePtr pDraw)
pPriv->last_swap_ust = 0;
list_init(&pPriv->reference_list);
pPriv->serialNumber = DRI2DrawableSerial(pDraw);
+ pPriv->needInvalidate = FALSE;
if (pDraw->type == DRAWABLE_WINDOW) {
pWin = (WindowPtr) pDraw;