summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUli Schlachter <psychon@znc.in>2011-06-13 11:26:55 +0200
committerUli Schlachter <psychon@znc.in>2011-06-24 15:24:09 +0200
commitd246d97592fc9df7ac914e1f97e2d834c7b975a5 (patch)
treed75976a5669d032b5970891711611f8aca40c1bd
parentcb3d91201c3de6c9cd1fd97b8471d322b75eec5a (diff)
xcb: Prettify some code
Instead of having each case do the same thing, this code will now fall through to the default case. Signed-off-by: Uli Schlachter <psychon@znc.in>
-rw-r--r--src/cairo-xcb-surface-render.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/src/cairo-xcb-surface-render.c b/src/cairo-xcb-surface-render.c
index bc8f2a66..9272c1ed 100644
--- a/src/cairo-xcb-surface-render.c
+++ b/src/cairo-xcb-surface-render.c
@@ -200,10 +200,12 @@ _render_operator (cairo_operator_t op)
C(ADD, ADD);
C(SATURATE, SATURATE);
+ /* PDF operators were added in RENDER 0.11, check if the xcb headers have
+ * the defines, else fall through to the default case. */
#if CAIRO_XCB_RENDER_AT_LEAST(0, 11)
#define BLEND(x,y) C(x,y)
#else
-#define BLEND(x,y) case CAIRO_OPERATOR_##x: ASSERT_NOT_REACHED; return XCB_RENDER_PICT_OP_OVER
+#define BLEND(x,y) case CAIRO_OPERATOR_##x:
#endif
BLEND(MULTIPLY, MULTIPLY);
BLEND(SCREEN, SCREEN);