DRI2: initialize event->drawable in DRI2SwapEvent

We weren't initialising the drawable in the event structure so the
client side DRI2WireToEvent used for translating the event into a GLX
event wouldn't be able to lookup up the corresponding GLXDrawable before
passing the event on.

Signed-off-by: Robert Bragg <robert@linux.intel.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
Signed-off-by: Keith Packard <keithp@keithp.com>
This commit is contained in:
Robert Bragg 2010-01-27 20:38:38 +00:00 committed by Keith Packard
parent 780c95caf9
commit 4b55b2cf8a

View File

@ -353,10 +353,12 @@ DRI2SwapEvent(ClientPtr client, void *data, int type, CARD64 ust, CARD64 msc,
CARD64 sbc)
{
xDRI2BufferSwapComplete event;
DrawablePtr pDrawable = data;
event.type = DRI2EventBase + DRI2_BufferSwapComplete;
event.sequenceNumber = client->sequence;
event.event_type = type;
event.drawable = pDrawable->id;
event.ust_hi = (CARD64)ust >> 32;
event.ust_lo = ust & 0xffffffff;
event.msc_hi = (CARD64)msc >> 32;