From 55ede2cf717f2e072d1b6b6db5949ec16326e28b Mon Sep 17 00:00:00 2001 From: Sven Verdoolaege Date: Sat, 19 Nov 2011 14:47:58 +0100 Subject: [PATCH] isl_set_from_pw_aff: handle NULL input Signed-off-by: Sven Verdoolaege --- isl_aff.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/isl_aff.c b/isl_aff.c index 23d17f02..a6573be8 100644 --- a/isl_aff.c +++ b/isl_aff.c @@ -1422,6 +1422,8 @@ __isl_give isl_map *isl_map_from_pw_aff(__isl_take isl_pw_aff *pwaff) */ __isl_give isl_set *isl_set_from_pw_aff(__isl_take isl_pw_aff *pwaff) { + if (!pwaff) + return NULL; if (!isl_space_is_set(pwaff->dim)) isl_die(isl_pw_aff_get_ctx(pwaff), isl_error_invalid, "space of input is not a set", -- 2.11.4.GIT