mirror of
https://gitlab.freedesktop.org/cairo/cairo.git
synced 2026-05-05 00:38:06 +02:00
win32: Check for damage before blitting
During the surface flush, we reduce any pending damage and then blit. If no damage had been accrued then the damage->region would be NULL leading to a segfault. Patch suggested by Szuromi Gábor. Reported-by: Szuromi Gábor <kukkerman@gmail.com> Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=47605 Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
This commit is contained in:
parent
0a778d974f
commit
86a89a8c1d
1 changed files with 1 additions and 1 deletions
|
|
@ -516,7 +516,7 @@ _cairo_win32_display_surface_flush (void *abstract_surface)
|
|||
0, 0,
|
||||
SRCCOPY))
|
||||
status = _cairo_win32_print_gdi_error (__FUNCTION__);
|
||||
} else {
|
||||
} else if (damage->region) {
|
||||
int n = cairo_region_num_rectangles (damage->region), i;
|
||||
for (i = 0; i < n; i++) {
|
||||
cairo_rectangle_int_t rect;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue