From 3d8be047c7ef6aa2ef8d965a2573620a75c41e82 Mon Sep 17 00:00:00 2001 From: Sven Verdoolaege Date: Sun, 19 Apr 2015 19:54:19 +0200 Subject: [PATCH] isl_tab_pip.c: gbr_get_sample: do not try to restore possibly corrupted tableau When isl_tab_sample fails, it may have left the tableau in an inconsistent state. Do not try to perform a rollback on this tableau. Signed-off-by: Sven Verdoolaege --- isl_tab_pip.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/isl_tab_pip.c b/isl_tab_pip.c index 2a4a4f73..fb2e72ca 100644 --- a/isl_tab_pip.c +++ b/isl_tab_pip.c @@ -2790,7 +2790,7 @@ static struct isl_vec *gbr_get_sample(struct isl_context_gbr *cgbr) sample = isl_tab_sample(cgbr->tab); - if (isl_tab_rollback(cgbr->tab, snap) < 0) { + if (!sample || isl_tab_rollback(cgbr->tab, snap) < 0) { isl_vec_free(sample); return NULL; } -- 2.11.4.GIT