XFlush(dpy); if (xdamage_base_event_type) { while (XCheckTypedEvent(dpy, xdamage_base_event_type+XDamageNotify, &ev)) { ; } }
void destroy_xdamage(void) {#if LIBVNCSERVER_HAVE_LIBXDAMAGE	if (xdamage) {		X_LOCK;		XDamageDestroy(dpy, xdamage);		X_UNLOCK;		rfbLog("destroyed xdamage object: 0x%lx\n", xdamage);		xdamage = 0;	}#endif}