diff options
author | Benjamin Otte <otte@gnome.org> | 2009-09-17 13:19:04 +0200 |
---|---|---|
committer | Benjamin Otte <otte@gnome.org> | 2009-10-20 00:40:40 +0200 |
commit | fa49ef81f7b39d32b626ed235958448835e2d2c2 (patch) | |
tree | b8f918908e9d371184a900c3b9e7fd0feaa31d89 /test | |
parent | 5c3ef4e9798f3395c55fe7b57df32f77c0de2c71 (diff) |
Add default cases for all switch statements
Fixes compilation with -Wswitch-default. Compilation with -Wswitch-enums
works fine as is.
Diffstat (limited to 'test')
-rw-r--r-- | test/composite.c | 18 | ||||
-rw-r--r-- | test/scaling-test.c | 3 |
2 files changed, 21 insertions, 0 deletions
diff --git a/test/composite.c b/test/composite.c index 7996251..594e8cc 100644 --- a/test/composite.c +++ b/test/composite.c @@ -407,6 +407,22 @@ calc_op (pixman_op_t op, double src, double dst, double srca, double dsta) Fb = max (0.0, 1.0 - srca / dsta); return mult_chan (src, dst, Fa, Fb); + case PIXMAN_OP_MULTIPLY: + case PIXMAN_OP_SCREEN: + case PIXMAN_OP_OVERLAY: + case PIXMAN_OP_DARKEN: + case PIXMAN_OP_LIGHTEN: + case PIXMAN_OP_COLOR_DODGE: + case PIXMAN_OP_COLOR_BURN: + case PIXMAN_OP_HARD_LIGHT: + case PIXMAN_OP_SOFT_LIGHT: + case PIXMAN_OP_DIFFERENCE: + case PIXMAN_OP_EXCLUSION: + case PIXMAN_OP_HSL_HUE: + case PIXMAN_OP_HSL_SATURATION: + case PIXMAN_OP_HSL_COLOR: + case PIXMAN_OP_HSL_LUMINOSITY: + case PIXMAN_OP_NONE: default: abort(); } @@ -866,6 +882,8 @@ main (void) ok = composite_test (&dst, op, &src, &mask, mask.size? TRUE : FALSE); break; + default: + break; } group_ok = group_ok && ok; tests_passed += ok; diff --git a/test/scaling-test.c b/test/scaling-test.c index 8899c59..c158c23 100644 --- a/test/scaling-test.c +++ b/test/scaling-test.c @@ -326,6 +326,9 @@ test_composite (uint32_t initcrc, case 3: repeat = PIXMAN_REPEAT_REFLECT; break; + + default: + break; } pixman_image_set_repeat (src_img, repeat); |