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:
5fd6b0d
)
isl_pw_aff_set_rational: avoid invalid access on error
author
Sven Verdoolaege
<skimo@kotnet.org>
Sun, 2 Dec 2012 11:12:14 +0000
(12:12 +0100)
committer
Sven Verdoolaege
<skimo@kotnet.org>
Sun, 2 Dec 2012 11:23:44 +0000
(12:23 +0100)
Signed-off-by: Sven Verdoolaege <skimo@kotnet.org>
isl_aff.c
patch
|
blob
|
history
diff --git
a/isl_aff.c
b/isl_aff.c
index
d8b89ce
..
e9d7286
100644
(file)
--- a/
isl_aff.c
+++ b/
isl_aff.c
@@
-2626,14
+2626,15
@@
__isl_give isl_pw_aff *isl_pw_aff_set_rational(__isl_take isl_pw_aff *pwaff)
__isl_give isl_pw_aff_list *isl_pw_aff_list_set_rational(
__isl_take isl_pw_aff_list *list)
{
- int i;
+ int i
, n
;
if (!list)
return NULL;
if (list->n == 0)
return list;
- for (i = 0; i < list->n; ++i) {
+ n = list->n;
+ for (i = 0; i < n; ++i) {
isl_pw_aff *pa;
pa = isl_pw_aff_list_get_pw_aff(list, i);