st/xlib: Support unlimited number of display connections
authorGeorge Kyriazis <george.kyriazis@intel.com>
Thu, 3 Mar 2016 01:28:00 +0000 (18:28 -0700)
committerBrian Paul <brianp@vmware.com>
Fri, 4 Mar 2016 17:57:09 +0000 (10:57 -0700)
commit51e562c3ea984f476efc0c4cbd01a4b718f3a007
treecbfa5059abedd7f72bb9f2c43c09645a22d121f0
parent192ee9adb1c092cf01860d23e13f373fb041c698
st/xlib: Support unlimited number of display connections

There is a limit of 10 display connections, which was a
problem for apps/tests that were continuously opening/closing display
connections.

This fix uses XAddExtension() and XESetCloseDisplay() to keep track
of the status of the display connections from the X server, freeing
mesa-related data as X displays get destroyed by the X server.

Poster child is the VTK "TimingTests"

Tested-by: Brian Paul <brianp@vmware.com>
Reviewed-by: Brian Paul <brianp@vmware.com>
src/gallium/state_trackers/glx/xlib/xm_api.c