diff options
author | Chris Wilson <chris@chris-wilson.co.uk> | 2008-01-10 13:08:23 +0000 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2008-01-10 13:14:28 +0000 |
commit | f4e7e7d6b4bb8e96dc8aef1ac673b8d64f65634c (patch) | |
tree | 2072bbc6b489e7705a760caa8b7b0944f8388431 /src/cairo-path-bounds.c | |
parent | 5fad969317186520ebbe09f3767907fb3bfd6164 (diff) | |
download | cairo-f4e7e7d6b4bb8e96dc8aef1ac673b8d64f65634c.tar.gz |
[cairo-path-bounds] _cairo_path_fixed_bounds() should never fail.
_cairo_path_fixed_bounds() should never fail so change return type
to void and update caller.
Diffstat (limited to 'src/cairo-path-bounds.c')
-rw-r--r-- | src/cairo-path-bounds.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/cairo-path-bounds.c b/src/cairo-path-bounds.c index 49b4ab983..55a64e537 100644 --- a/src/cairo-path-bounds.c +++ b/src/cairo-path-bounds.c @@ -148,7 +148,7 @@ _cairo_path_bounder_close_path (void *closure) } /* XXX: Perhaps this should compute a PixRegion rather than 4 doubles */ -cairo_status_t +void _cairo_path_fixed_bounds (cairo_path_fixed_t *path, double *x1, double *y1, double *x2, double *y2) @@ -165,7 +165,9 @@ _cairo_path_fixed_bounds (cairo_path_fixed_t *path, _cairo_path_bounder_curve_to, _cairo_path_bounder_close_path, &bounder); - if (status || ! bounder.has_point) { + assert (status == CAIRO_STATUS_SUCCESS); + + if (! bounder.has_point) { *x1 = *y1 = *x2 = *y2 = 0.; } else { *x1 = _cairo_fixed_to_double (bounder.min_x); @@ -175,6 +177,4 @@ _cairo_path_fixed_bounds (cairo_path_fixed_t *path, } _cairo_path_bounder_fini (&bounder); - - return status; } |