Fix leak in rectilinear stroking code

The code was not cleaning up after itself when rejecting a path as
rectilinear.
This commit is contained in:
Behdad Esfahbod 2007-03-01 18:36:16 -05:00
parent 2acd5b5277
commit dcdcb7ac2a

View file

@ -1282,16 +1282,17 @@ _cairo_path_fixed_stroke_rectilinear (cairo_path_fixed_t *path,
NULL,
_cairo_rectilinear_stroker_close_path,
&rectilinear_stroker);
if (status) {
_cairo_traps_fini (traps);
return status;
}
if (status)
goto BAIL;
status = _cairo_rectilinear_stroker_emit_segments (&rectilinear_stroker);
if (status)
return status;
BAIL:
_cairo_rectilinear_stroker_fini (&rectilinear_stroker);
return CAIRO_STATUS_SUCCESS;
if (status)
_cairo_traps_fini (traps);
return status;
}