diff options
author | Clément Bœsch <u@pkh.me> | 2015-09-11 22:06:15 +0300 |
---|---|---|
committer | Clément Bœsch <clement@stupeflix.com> | 2015-09-12 18:50:22 +0300 |
commit | 2c364ef82dcc196b1b016cff16887280e8a64fa9 (patch) | |
tree | 3dfe03df6b1ab69cefc5d3066f8d940bf9360986 /libavdevice/caca.c | |
parent | 79f0f1a80bd03bd66fbf52cbff0892aba68b155a (diff) |
avdevice/caca: small trivial macros adjustments
Diffstat (limited to 'libavdevice/caca.c')
-rw-r--r-- | libavdevice/caca.c | 18 |
1 files changed, 10 insertions, 8 deletions
diff --git a/libavdevice/caca.c b/libavdevice/caca.c index 574b7f31d1..14775d2c7d 100644 --- a/libavdevice/caca.c +++ b/libavdevice/caca.c @@ -73,7 +73,7 @@ static void list_drivers(CACAContext *c) } #define DEFINE_LIST_DITHER(thing, thing_str) \ -static void list_dither_## thing(CACAContext *c) \ +static void list_dither_## thing(CACAContext *c) \ { \ const char *const *thing = caca_get_dither_## thing ##_list(c->dither); \ int i; \ @@ -150,13 +150,15 @@ static int caca_write_header(AVFormatContext *s) goto fail; } -#define CHECK_DITHER_OPT(opt) \ - if (caca_set_dither_##opt(c->dither, c->opt) < 0) { \ - ret = AVERROR(errno); \ - av_log(s, AV_LOG_ERROR, "Failed to set value '%s' for option '%s'\n", \ - c->opt, #opt); \ - goto fail; \ - } +#define CHECK_DITHER_OPT(opt) do { \ + if (caca_set_dither_##opt(c->dither, c->opt) < 0) { \ + ret = AVERROR(errno); \ + av_log(s, AV_LOG_ERROR, "Failed to set value '%s' for option '%s'\n", \ + c->opt, #opt); \ + goto fail; \ + } \ +} while (0) + CHECK_DITHER_OPT(algorithm); CHECK_DITHER_OPT(antialias); CHECK_DITHER_OPT(charset); |