[cairo] [PATCH 5/5] fallback: Silence gcc warning

Maarten Bosmans mkbosmans at gmail.com
Fri Mar 18 11:27:51 PDT 2011

2011/3/18 Andrea Canciani <ranma42 at gmail.com>:
> gcc complains that
> cairo-surface-wrapper.c:647: warning: ignoring return value of
> ‘_cairo_rectangle_intersect’, declared with attribute warn_unused_result
> Storing the result in a variable (which is otherwise unused) makes gcc
> happy.

Wouldn't that make GCC complain (but perhaps not in with the default
warning settings) about a set but never read variable? At least the
clang static code analyzer would complain for sure.

The solution Bill gives looks more reasonable.


More information about the cairo mailing list