Mesa (mesa_7_6_branch): unichrome: Silence compiler warnings.

Vinson Lee vlee at kemper.freedesktop.org
Wed Dec 16 01:40:15 UTC 2009


Module: Mesa
Branch: mesa_7_6_branch
Commit: dc0a1ebc7369da62c2dfbd5ea8dec3273e099725
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=dc0a1ebc7369da62c2dfbd5ea8dec3273e099725

Author: Vinson Lee <vlee at vmware.com>
Date:   Tue Dec 15 17:39:30 2009 -0800

unichrome: Silence compiler warnings.

---

 src/mesa/drivers/dri/unichrome/via_ioctl.c  |    3 ---
 src/mesa/drivers/dri/unichrome/via_screen.c |    2 ++
 src/mesa/drivers/dri/unichrome/via_tris.c   |    3 ++-
 src/mesa/tnl_dd/t_dd_tritmp.h               |    4 ++--
 4 files changed, 6 insertions(+), 6 deletions(-)

diff --git a/src/mesa/drivers/dri/unichrome/via_ioctl.c b/src/mesa/drivers/dri/unichrome/via_ioctl.c
index 6746f55..91c94fa 100644
--- a/src/mesa/drivers/dri/unichrome/via_ioctl.c
+++ b/src/mesa/drivers/dri/unichrome/via_ioctl.c
@@ -885,9 +885,6 @@ void viaFlushDmaLocked(struct via_context *vmesa, GLuint flags)
    }
    else if (vmesa->numClipRects) {
       drm_clip_rect_t *pbox = vmesa->pClipRects;
-      __DRIdrawablePrivate *dPriv = vmesa->driDrawable;
-      struct via_renderbuffer *const vrb = 
-	(struct via_renderbuffer *) dPriv->driverPrivate;
 
       for (i = 0; i < vmesa->numClipRects; i++) {
 	 drm_clip_rect_t b;
diff --git a/src/mesa/drivers/dri/unichrome/via_screen.c b/src/mesa/drivers/dri/unichrome/via_screen.c
index 3dbb570..54019fd 100644
--- a/src/mesa/drivers/dri/unichrome/via_screen.c
+++ b/src/mesa/drivers/dri/unichrome/via_screen.c
@@ -210,7 +210,9 @@ viaCreateBuffer(__DRIscreenPrivate *driScrnPriv,
                 const __GLcontextModes *mesaVis,
                 GLboolean isPixmap)
 {
+#if 000
     viaScreenPrivate *screen = (viaScreenPrivate *) driScrnPriv->private;
+#endif
 
     GLboolean swStencil = (mesaVis->stencilBits > 0 && 
 			   mesaVis->depthBits != 24);
diff --git a/src/mesa/drivers/dri/unichrome/via_tris.c b/src/mesa/drivers/dri/unichrome/via_tris.c
index 79e6762..e2f1f02 100644
--- a/src/mesa/drivers/dri/unichrome/via_tris.c
+++ b/src/mesa/drivers/dri/unichrome/via_tris.c
@@ -330,7 +330,8 @@ do {							\
 
 #define LOCAL_VARS(n)                                                   \
     struct via_context *vmesa = VIA_CONTEXT(ctx);                             \
-    GLuint color[n], spec[n];                                           \
+    GLuint color[n] = { 0 };                                          \
+    GLuint spec[n] = { 0 };                                           \
     GLuint coloroffset = vmesa->coloroffset;              \
     GLuint specoffset = vmesa->specoffset;                       \
     (void)color; (void)spec; (void)coloroffset; (void)specoffset;
diff --git a/src/mesa/tnl_dd/t_dd_tritmp.h b/src/mesa/tnl_dd/t_dd_tritmp.h
index 1ae70f4..c3ba851 100644
--- a/src/mesa/tnl_dd/t_dd_tritmp.h
+++ b/src/mesa/tnl_dd/t_dd_tritmp.h
@@ -132,7 +132,7 @@ static void TAG(triangle)( GLcontext *ctx, GLuint e0, GLuint e1, GLuint e2 )
    struct vertex_buffer *VB = &TNL_CONTEXT( ctx )->vb;
    VERTEX *v[3];
    GLfloat offset = 0;
-   GLfloat z[3];
+   GLfloat z[3] = { 0 };
    GLenum mode = GL_FILL;
    GLuint facing = 0;
    LOCAL_VARS(3);
@@ -395,7 +395,7 @@ static void TAG(quadr)( GLcontext *ctx,
    struct vertex_buffer *VB = &TNL_CONTEXT( ctx )->vb;
    VERTEX *v[4];
    GLfloat offset = 0;
-   GLfloat z[4];
+   GLfloat z[4] = { 0 };
    GLenum mode = GL_FILL;
    GLuint facing = 0;
    LOCAL_VARS(4);




More information about the mesa-commit mailing list