mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-05-07 10:58:15 +02:00
[cairo-pattern] Add an ASSERT_NOT_REACHED
On the default case for an unknown pattern type, add an assert that the code is never reached, and just in case upgrade the error to a fatal PATTERN_TYPE_MISMATCH.
This commit is contained in:
parent
973d5fa8a5
commit
481b88dd6b
1 changed files with 2 additions and 1 deletions
|
|
@ -1828,7 +1828,8 @@ _cairo_pattern_acquire_surface (cairo_pattern_t *pattern,
|
|||
attributes);
|
||||
} break;
|
||||
default:
|
||||
status = CAIRO_INT_STATUS_UNSUPPORTED;
|
||||
ASSERT_NOT_REACHED;
|
||||
status = _cairo_error (CAIRO_STATUS_PATTERN_TYPE_MISMATCH);
|
||||
}
|
||||
|
||||
return status;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue