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:
529c3fd
)
isl_sample.c: interval_sample: avoid NULL pointer dereference
author
Sven Verdoolaege
<skimo@kotnet.org>
Fri, 25 Jun 2010 16:43:01 +0000
(18:43 +0200)
committer
Sven Verdoolaege
<skimo@kotnet.org>
Sat, 26 Jun 2010 15:37:39 +0000
(17:37 +0200)
isl_sample.c
patch
|
blob
|
history
diff --git
a/isl_sample.c
b/isl_sample.c
index
3564f80
..
8a99d7e
100644
(file)
--- a/
isl_sample.c
+++ b/
isl_sample.c
@@
-61,6
+61,10
@@
static struct isl_vec *interval_sample(struct isl_basic_set *bset)
return zero_sample(bset);
sample = isl_vec_alloc(bset->ctx, 2);
+ if (!sample)
+ goto error;
+ if (!bset)
+ return NULL;
isl_int_set_si(sample->block.data[0], 1);
if (bset->n_eq > 0) {