On 05/14/2014 10:55 AM, Juha-Pekka Heikkila wrote:
> Signed-off-by: Juha-Pekka Heikkila <[email protected]>
> ---
> src/glsl/link_uniform_blocks.cpp | 5 +++++
> 1 file changed, 5 insertions(+)
>
> diff --git a/src/glsl/link_uniform_blocks.cpp
> b/src/glsl/link_uniform_blocks.cpp
> index 1a0e643..3643734 100644
> --- a/src/glsl/link_uniform_blocks.cpp
> +++ b/src/glsl/link_uniform_blocks.cpp
> @@ -170,6 +170,11 @@ link_uniform_blocks(void *mem_ctx,
> struct hash_table *block_hash =
> _mesa_hash_table_create(mem_ctx, _mesa_key_string_equal);
>
> + if (block_hash == NULL) {
> + _mesa_error_no_memory(__func__);
> + return 0;
> + }
> +
This should also call linker_error, and the caller
(link_intrastage_shaders) should follow the call to link_uniform_blocks with
if (!prog->LinkStatus)
return NULL;
> /* Determine which uniform blocks are active.
> */
> link_uniform_block_active_visitor v(mem_ctx, block_hash, prog);
>
_______________________________________________
mesa-dev mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/mesa-dev