Re: [PATCH wayland 1/2] scanner: check wl_array_add result

2014-05-06 Thread Kristian Høgsberg
On Mon, May 05, 2014 at 02:45:19PM -0700, U. Artie Eoff wrote:
> Signed-off-by: U. Artie Eoff 

Thanks, applied.

Kristian

> ---
>  src/scanner.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/src/scanner.c b/src/scanner.c
> index 622d4d8..dd1c7b6 100644
> --- a/src/scanner.c
> +++ b/src/scanner.c
> @@ -1039,7 +1039,7 @@ emit_types_forward_declarations(struct protocol 
> *protocol,
>   continue;
>  
>   m->all_null = 0;
> - p = wl_array_add(types, sizeof *p);
> + p = fail_on_null(wl_array_add(types, sizeof 
> *p));
>   *p = a->interface_name;
>   break;
>   default:
> -- 
> 1.9.0
> 
> ___
> wayland-devel mailing list
> wayland-devel@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/wayland-devel
___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel


[PATCH wayland 1/2] scanner: check wl_array_add result

2014-05-05 Thread U. Artie Eoff
Signed-off-by: U. Artie Eoff 
---
 src/scanner.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/scanner.c b/src/scanner.c
index 622d4d8..dd1c7b6 100644
--- a/src/scanner.c
+++ b/src/scanner.c
@@ -1039,7 +1039,7 @@ emit_types_forward_declarations(struct protocol *protocol,
continue;
 
m->all_null = 0;
-   p = wl_array_add(types, sizeof *p);
+   p = fail_on_null(wl_array_add(types, sizeof 
*p));
*p = a->interface_name;
break;
default:
-- 
1.9.0

___
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/wayland-devel