diff options
author | Vinson Lee <vlee@vmware.com> | 2009-12-08 18:26:05 -0800 |
---|---|---|
committer | Vinson Lee <vlee@vmware.com> | 2009-12-08 18:26:05 -0800 |
commit | af16c822a5af8ce0aa7582e8ea44315b62b7356b (patch) | |
tree | 4591a62571814d66f57862aa236a614f139b401e | |
parent | d33bf38d63d233f6a09115acfff230c464d3ee29 (diff) |
mesa: Fix array out-of-bounds access by _mesa_LightModeli.
_mesa_LightModeli calls _mesa_LightModeliv, which uses the
params argument as an array.
-rw-r--r-- | src/mesa/main/light.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/mesa/main/light.c b/src/mesa/main/light.c index 10c89f4368..5a8f9160f6 100644 --- a/src/mesa/main/light.c +++ b/src/mesa/main/light.c @@ -537,7 +537,10 @@ _mesa_LightModeliv( GLenum pname, const GLint *params ) void GLAPIENTRY _mesa_LightModeli( GLenum pname, GLint param ) { - _mesa_LightModeliv( pname, ¶m ); + GLint iparam[4]; + iparam[0] = param; + iparam[1] = iparam[2] = iparam[3] = 0; + _mesa_LightModeliv( pname, iparam ); } |