glretrace: avoid glXSwapBuffers failures because of "bad" windows

Both Mesa's and NVIDIA's libGL generate an X protocol error in
glXSwapBuffers() if the window has never been bound with
glXMakeCurrent().  That causes glretrace to exit.  The X protocol
error can't be trapped with XSetErrorHandler() for some reason.
So, keep track of whether a window has ever been bound and skip
glXSwapBuffers if the window has never been bound.

This allows some WGL-based apitraces to be replayed on Linux/GLX.

Reviewed-by: Jose Fonseca <jfonseca@vmware.com>