diff options
Diffstat (limited to 'src/backend_libtiff.c')
-rw-r--r-- | src/backend_libtiff.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/src/backend_libtiff.c b/src/backend_libtiff.c index 82ce48e..482a80b 100644 --- a/src/backend_libtiff.c +++ b/src/backend_libtiff.c @@ -1,6 +1,8 @@ #include "backend_libtiff.h" #include "backend.h" #include "source.h" + +#include <assert.h> #include <stdlib.h> #include <stdio.h> #include <sys/mman.h> @@ -89,11 +91,7 @@ static struct imv_bitmap *to_imv_bitmap(int width, int height, void *bitmap) static void report_error(struct imv_source *src) { - if (!src->callback) { - fprintf(stderr, "imv_source(%s) has no callback configured. " - "Discarding error.\n", src->name); - return; - } + assert(src->callback); struct imv_source_message msg; msg.source = src; @@ -107,11 +105,7 @@ static void report_error(struct imv_source *src) static void send_bitmap(struct imv_source *src, void *bitmap) { - if (!src->callback) { - fprintf(stderr, "imv_source(%s) has no callback configured. " - "Discarding result.\n", src->name); - return; - } + assert(src->callback); struct imv_source_message msg; msg.source = src; |