aboutsummaryrefslogtreecommitdiffstats
path: root/src/output.c
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2016-07-13 16:27:19 +0200
committerMattias Andrée <maandree@kth.se>2016-07-13 16:27:19 +0200
commit7ad8d3742182936e9c33d0cd65716bcf68e43987 (patch)
treed4540531b0070b3ab4256c5badee5495e6146cb1 /src/output.c
parenttypo (diff)
downloadcoopgammad-7ad8d3742182936e9c33d0cd65716bcf68e43987.tar.gz
coopgammad-7ad8d3742182936e9c33d0cd65716bcf68e43987.tar.bz2
coopgammad-7ad8d3742182936e9c33d0cd65716bcf68e43987.tar.xz
Print warninging when attemping to remove non-existing filter
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r--src/output.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/output.c b/src/output.c
index f3259e0..f323ff0 100644
--- a/src/output.c
+++ b/src/output.c
@@ -18,6 +18,7 @@
#include "output.h"
#include "util.h"
+#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -273,7 +274,11 @@ static ssize_t remove_filter(struct output* out, struct filter* filter)
break;
if (i == out->table_size)
- return (ssize_t)(out->table_size);
+ {
+ fprintf(stderr, "%s: ignoring attempt to removing non-existing filter on CRTC %s: %s",
+ argv0, out->name, filter->class);
+ return (ssize_t)(out->table_size);
+ }
filter_destroy(out->table_filters + i);
libgamma_gamma_ramps8_destroy(&(out->table_sums[i].u8));