glx: Make drawables persistent untill they are changed by glXMakeCurrent
glx: Make drawables persistent untill they are changed by glXMakeCurrent

This fixes bug that xdemos/manywin would segfault if it was run with command
./manywin 2. Demo is tring to call glXSwapBuffers while another context was
bind using glXMakeCurrent.

Fix is simple makes drawable and readable persistent untill they change or
context is destroyed.

I found a logic error when same dri context is used for multiple drawables
which caused readable and drawable to fall out of sync in special case. Fix
is simple just updating  drawables more often than in original patch.

Signed-off-by: Pauli Nieminen <ce89c68871fad9564c22852774cc328c5c04372c@gmail.com>

adobe/glsl2agal,wolf96/glsl-optimizer,tokyovigilante/glsl-optimizer,jbarczak/glsl-optimizer,KTXSoftware/glsl2agal,bkaradzic/glsl-optimizer,mcanthony/glsl-optimizer,tokyovigilante/glsl-optimizer,adobe/glsl2agal,adobe/glsl2agal,dellis1972/glsl-optimizer,mcanthony/glsl-optimizer,dellis1972/glsl-optimizer,mapbox/glsl-optimizer,zz85/glsl-optimizer,benaadams/glsl-optimizer,tokyovigilante/glsl-optimizer,zeux/glsl-optimizer,zeux/glsl-optimizer,KTXSoftware/glsl2agal,wolf96/glsl-optimizer,benaadams/glsl-optimizer,bkaradzic/glsl-optimizer,metora/MesaGLSLCompiler,djreep81/glsl-optimizer,dellis1972/glsl-optimizer,metora/MesaGLSLCompiler,KTXSoftware/glsl2agal,tokyovigilante/glsl-optimizer,djreep81/glsl-optimizer,wolf96/glsl-optimizer,zeux/glsl-optimizer,zeux/glsl-optimizer,dellis1972/glsl-optimizer,mcanthony/glsl-optimizer,zz85/glsl-optimizer,djreep81/glsl-optimizer,KTXSoftware/glsl2agal,wolf96/glsl-optimizer,tokyovigilante/glsl-optimizer,mapbox/glsl-optimizer,benaadams/glsl-optimizer,jbarczak/glsl-optimizer,dellis1972/glsl-optimizer,zeux/glsl-optimizer,benaadams/glsl-optimizer,djreep81/glsl-optimizer,mapbox/glsl-optimizer,bkaradzic/glsl-optimizer,zz85/glsl-optimizer,metora/MesaGLSLCompiler,KTXSoftware/glsl2agal,benaadams/glsl-optimizer,adobe/glsl2agal,adobe/glsl2agal,mapbox/glsl-optimizer,bkaradzic/glsl-optimizer,jbarczak/glsl-optimizer,bkaradzic/glsl-optimizer,zz85/glsl-optimizer,jbarczak/glsl-optimizer,djreep81/glsl-optimizer,jbarczak/glsl-optimizer,zz85/glsl-optimizer,benaadams/glsl-optimizer,wolf96/glsl-optimizer,mapbox/glsl-optimizer,mcanthony/glsl-optimizer,mcanthony/glsl-optimizer,zz85/glsl-optimizer