[Mesa-dev] [PATCH 3/3] mesa: Deal with size differences between GLuint and GLhandleARB in GetAttachedObjectsARB

Matt Turner mattst88 at gmail.com
Thu Jan 21 08:42:10 PST 2016


On Wed, Jan 20, 2016 at 5:14 PM, Jeremy Huddleston Sequoia
<jeremyhu at apple.com> wrote:
> Signed-off-by: Jeremy Huddleston Sequoia <jeremyhu at apple.com>
> ---
>  src/mesa/main/shaderapi.c | 12 +++++++++++-
>  1 file changed, 11 insertions(+), 1 deletion(-)
>
> diff --git a/src/mesa/main/shaderapi.c b/src/mesa/main/shaderapi.c
> index a988f41..75fc17c 100644
> --- a/src/mesa/main/shaderapi.c
> +++ b/src/mesa/main/shaderapi.c
> @@ -1374,10 +1374,20 @@ _mesa_DetachShader(GLuint program, GLuint shader)
>
>  void GLAPIENTRY
>  _mesa_GetAttachedObjectsARB(GLhandleARB container, GLsizei maxCount,
> -                            GLsizei * count, GLhandleARB * obj)
> +                            GLsizei * count, GLhandleARB * objARB)
>  {
> +   int i;
> +   GLuint *obj = calloc(maxCount, sizeof(GLuint));
> +   assert(obj);
> +
>     GET_CURRENT_CONTEXT(ctx);
>     get_attached_shaders(ctx, container, maxCount, count, obj);
> +
> +   for (i=0 ; i < *count; i++) {

Spaces around =


More information about the mesa-dev mailing list