Added few more stubs so that control reaches to DestroyDevice().
[mesa.git] / src / glx / dri2_glx.c
index bed25bb38d609b40334234d270c2bf4188a42c15..af50fbe9d9c86c2738d4e9d1ed38b94622508c32 100644 (file)
@@ -50,7 +50,7 @@
 #include "dri2_priv.h"
 #include "loader.h"
 
-/* From xmlpool/options.h, user exposed so should be stable */
+/* From driconf.h, user exposed so should be stable */
 #define DRI_CONF_VBLANK_NEVER 0
 #define DRI_CONF_VBLANK_DEF_INTERVAL_0 1
 #define DRI_CONF_VBLANK_DEF_INTERVAL_1 2
@@ -599,7 +599,7 @@ __dri2CopySubBuffer(__GLXDRIdrawable *pdraw, int x, int y,
    flags = __DRI2_FLUSH_DRAWABLE;
    if (flush)
       flags |= __DRI2_FLUSH_CONTEXT;
-   dri2Flush(psc, ctx, priv, flags, __DRI2_THROTTLE_SWAPBUFFER);
+   dri2Flush(psc, ctx, priv, flags, __DRI2_THROTTLE_COPYSUBBUFFER);
 
    region = XFixesCreateRegion(psc->base.dpy, &xrect, 1);
    DRI2CopyRegion(psc->base.dpy, pdraw->xDrawable, region,
@@ -776,7 +776,7 @@ static void show_fps(struct dri2_drawable *draw)
 
    if (draw->previous_time + interval * 1000000 <= current_time) {
       if (draw->previous_time) {
-         fprintf(stderr, "libGL: FPS = %.1f\n",
+         fprintf(stderr, "libGL: FPS = %.2f\n",
                  ((uint64_t)draw->frames * 1000000) /
                  (double)(current_time - draw->previous_time));
       }
@@ -1244,7 +1244,7 @@ dri2CreateScreen(int screen, struct glx_display * priv)
 
    psc->fd = loader_open_device(deviceName);
    if (psc->fd < 0) {
-      ErrorMessageF("failed to open drm device: %s\n", strerror(errno));
+      ErrorMessageF("failed to open %s: %s\n", deviceName, strerror(errno));
       goto handle_error;
    }