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

Author: Brian Paul <bri...@vmware.com>
Date:   Thu Aug 13 13:44:31 2009 -0600

mesa: fix some potential uninitialized memory references

---

 src/mesa/main/fog.c   |    2 +-
 src/mesa/main/light.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/src/mesa/main/fog.c b/src/mesa/main/fog.c
index 50a61bd..4323d3d 100644
--- a/src/mesa/main/fog.c
+++ b/src/mesa/main/fog.c
@@ -67,7 +67,7 @@ _mesa_Fogiv(GLenum pname, const GLint *params )
         break;
       default:
          /* Error will be caught later in _mesa_Fogfv */
-         ;
+         ASSIGN_4V(p, 0.0F, 0.0F, 0.0F, 0.0F);
    }
    _mesa_Fogfv(pname, p);
 }
diff --git a/src/mesa/main/light.c b/src/mesa/main/light.c
index ac604fd..1703468 100644
--- a/src/mesa/main/light.c
+++ b/src/mesa/main/light.c
@@ -496,7 +496,7 @@ _mesa_LightModeliv( GLenum pname, const GLint *params )
          break;
       default:
          /* Error will be caught later in gl_LightModelfv */
-         ;
+         ASSIGN_4V(fparam, 0.0F, 0.0F, 0.0F, 0.0F);
    }
    _mesa_LightModelfv( pname, fparam );
 }

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to