mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-24 08:50:13 +01:00
mesa: Fix array out-of-bounds access in _mesa_TexEnvf.
_mesa_TexEnvf calls _mesa_TexEnvfv, which uses the param argument
as an array.
(cherry picked from commit a11d60d14c)
This commit is contained in:
parent
4fb5ae7233
commit
fe8e18bcd4
1 changed files with 4 additions and 1 deletions
|
|
@ -598,7 +598,10 @@ _mesa_TexEnvfv( GLenum target, GLenum pname, const GLfloat *param )
|
|||
void GLAPIENTRY
|
||||
_mesa_TexEnvf( GLenum target, GLenum pname, GLfloat param )
|
||||
{
|
||||
_mesa_TexEnvfv( target, pname, ¶m );
|
||||
GLfloat p[4];
|
||||
p[0] = param;
|
||||
p[1] = p[2] = p[3] = 0.0;
|
||||
_mesa_TexEnvfv( target, pname, p );
|
||||
}
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue