On Mon, 8 Feb 2010 19:25:14 +0100 Francisco Jerez <curroje...@riseup.net> wrote:
> The spec says (regarding glXCreateWindow): "If there is already a > GLXFBConfig associated with win (as a result of a previous > glXCreateWindow call), then a BadAlloc error is generated.". It will > also come useful to implement DRI2InvalidateBuffers for the indirect > case. > > Signed-off-by: Francisco Jerez <curroje...@riseup.net> > --- > glx/glxcmds.c | 51 +++++++++++++++++++++++++++++++++++++++++++++------ > glx/glxserver.h | 1 + > 2 files changed, 46 insertions(+), 6 deletions(-) > > diff --git a/glx/glxcmds.c b/glx/glxcmds.c > index 77afbf4..0e1c89c 100644 > --- a/glx/glxcmds.c > +++ b/glx/glxcmds.c > @@ -51,6 +51,15 @@ > #include "indirect_table.h" > #include "indirect_util.h" > > +static int glxWindowPrivateKeyIndex; > +static DevPrivateKey glxWindowPrivateKey = &glxWindowPrivateKeyIndex; > + > +__GLXdrawable * > +glxGetDrawableFromWindow(WindowPtr pWin) > +{ > + return dixLookupPrivate(&pWin->devPrivates, glxWindowPrivateKey); > +} Thanks for pointing this out. Can we use this in glxscreens.c:glxDestroyWindow() to invalidate the drawable pointer in the glx drawable at window destroy time? That would be a good way to fix https://bugs.freedesktop.org/show_bug.cgi?id=26394; probably better than trying to mix in (or totally switch to) XIDs for tracking things. -- Jesse Barnes, Intel Open Source Technology Center _______________________________________________ xorg-devel@lists.x.org: X.Org development Archives: http://lists.x.org/archives/xorg-devel Info: http://lists.x.org/mailman/listinfo/xorg-devel