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>
This commit is contained in:
parent
3aca819940
commit
603fcb3abf
|
@ -181,6 +181,7 @@ DRI2AllocateDrawable(DrawablePtr pDraw)
|
||||||
pPriv->last_swap_ust = 0;
|
pPriv->last_swap_ust = 0;
|
||||||
list_init(&pPriv->reference_list);
|
list_init(&pPriv->reference_list);
|
||||||
pPriv->serialNumber = DRI2DrawableSerial(pDraw);
|
pPriv->serialNumber = DRI2DrawableSerial(pDraw);
|
||||||
|
pPriv->needInvalidate = FALSE;
|
||||||
|
|
||||||
if (pDraw->type == DRAWABLE_WINDOW) {
|
if (pDraw->type == DRAWABLE_WINDOW) {
|
||||||
pWin = (WindowPtr) pDraw;
|
pWin = (WindowPtr) pDraw;
|
||||||
|
|
Loading…
Reference in New Issue