X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=isl_ctx.c;h=515d865fd3da11839792449d49f47f3be1fcde83;hb=ac5bc82f1683ea8cc6b37dafc2b96ad1cf736cd3;hp=1dff37b377cdae051b870a45fa06e9212f348f54;hpb=df17c511ad4492bfa3aa164b4488d9f857888b13;p=platform%2Fupstream%2Fisl.git diff --git a/isl_ctx.c b/isl_ctx.c index 1dff37b..515d865 100644 --- a/isl_ctx.c +++ b/isl_ctx.c @@ -1,7 +1,7 @@ /* * Copyright 2008-2009 Katholieke Universiteit Leuven * - * Use of this software is governed by the GNU LGPLv2.1 license + * Use of this software is governed by the MIT license * * Written by Sven Verdoolaege, K.U.Leuven, Departement * Computerwetenschappen, Celestijnenlaan 200A, B-3001 Leuven, Belgium @@ -9,14 +9,17 @@ #include #include -#include +#include -void isl_handle_error(isl_ctx *ctx, int error, const char *msg, +void isl_handle_error(isl_ctx *ctx, enum isl_error error, const char *msg, const char *file, int line) { + if (!ctx) + return; + isl_ctx_set_error(ctx, error); - switch (isl_options_get_on_error(ctx)) { + switch (ctx->opt->on_error) { case ISL_ON_ERROR_WARN: fprintf(stderr, "%s:%d: %s\n", file, line, msg); return;