isl_ast_codegen.c: compute_domains: avoid invalid access on error
authorSven Verdoolaege <skimo@kotnet.org>
Sun, 2 Dec 2012 12:10:31 +0000 (13:10 +0100)
committerSven Verdoolaege <skimo@kotnet.org>
Sun, 2 Dec 2012 12:10:31 +0000 (13:10 +0100)
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
isl_ast_codegen.c

index 33edeaa..1ada490 100644 (file)
@@ -2587,6 +2587,9 @@ static __isl_give isl_basic_set_list *compute_domains(
        enum isl_ast_build_domain_type type;
        int empty;
 
+       if (!executed)
+               return NULL;
+
        ctx = isl_union_map_get_ctx(executed);
        domains.list = isl_basic_set_list_alloc(ctx, 0);