projects
/
platform
/
upstream
/
isl.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6817c5f
)
isl_merge_divs: handle NULL input
author
Sven Verdoolaege
<skimo@kotnet.org>
Wed, 18 Apr 2012 08:31:50 +0000
(10:31 +0200)
committer
Sven Verdoolaege
<skimo@kotnet.org>
Wed, 18 Apr 2012 08:58:37 +0000
(10:58 +0200)
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
isl_local_space.c
patch
|
blob
|
history
diff --git
a/isl_local_space.c
b/isl_local_space.c
index
19ae702
..
20e4070
100644
(file)
--- a/
isl_local_space.c
+++ b/
isl_local_space.c
@@
-413,8
+413,12
@@
__isl_give isl_mat *isl_merge_divs(__isl_keep isl_mat *div1,
{
int i, j, k;
isl_mat *div = NULL;
- unsigned d
= div1->n_col - div1->n_row
;
+ unsigned d;
+ if (!div1 || !div2)
+ return NULL;
+
+ d = div1->n_col - div1->n_row;
div = isl_mat_alloc(div1->ctx, 1 + div1->n_row + div2->n_row,
d + div1->n_row + div2->n_row);
if (!div)