OSDN Git Service

st/dri: Fix some warnings
authorJakob Bornecrantz <jakob@vmware.com>
Thu, 27 Aug 2009 16:38:33 +0000 (17:38 +0100)
committerJakob Bornecrantz <jakob@vmware.com>
Fri, 28 Aug 2009 10:46:17 +0000 (12:46 +0200)
src/gallium/state_trackers/dri/dri_context.c
src/gallium/state_trackers/dri/dri_drawable.c
src/gallium/state_trackers/dri/dri_drawable.h

index 830e511..8819936 100644 (file)
@@ -100,7 +100,6 @@ void
 dri_destroy_context(__DRIcontextPrivate * cPriv)
 {
    struct dri_context *ctx = dri_context(cPriv);
-   struct dri_screen *screen = dri_screen(cPriv->driScreenPriv);
 
    /* No particular reason to wait for command completion before
     * destroying a context, but it is probably worthwhile flushing it
@@ -140,7 +139,6 @@ dri_make_current(__DRIcontextPrivate * cPriv,
 {
    if (cPriv) {
       struct dri_context *ctx = dri_context(cPriv);
-      struct dri_screen *screen = dri_screen(cPriv->driScreenPriv);
       struct dri_drawable *draw = dri_drawable(driDrawPriv);
       struct dri_drawable *read = dri_drawable(driReadPriv);
       struct st_context *old_st = st_get_current();
index 200b4bd..2265187 100644 (file)
@@ -281,6 +281,8 @@ dri_flush_frontbuffer(struct pipe_screen *screen,
    /* TODO if rendering to pixmaps is slow enable this code. */
    if (drawable->is_pixmap)
       return;
+#else
+   (void)drawable;
 #endif
 
    (*dri_screen->dri2.loader->flushFrontBuffer)(dri_drawable,
index eaf0b95..9f9cb29 100644 (file)
@@ -33,6 +33,7 @@
 struct pipe_surface;
 struct pipe_fence_handle;
 struct st_framebuffer;
+struct dri_context;
 
 #define DRI_SWAP_FENCES_MAX  8
 #define DRI_SWAP_FENCES_MASK 7