mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-10 02:40:11 +00:00
renderer: return_if_fail() if the given texture size is 0
All renderers SEGV currently when that happens.
This commit is contained in:
parent
444d5fa500
commit
cfeaa0ac72
@ -372,6 +372,8 @@ gsk_renderer_render_texture (GskRenderer *renderer,
|
||||
gsk_render_node_get_bounds (root, &real_viewport);
|
||||
viewport = &real_viewport;
|
||||
}
|
||||
g_return_val_if_fail (viewport->size.width > 0, NULL);
|
||||
g_return_val_if_fail (viewport->size.height > 0, NULL);
|
||||
|
||||
texture = GSK_RENDERER_GET_CLASS (renderer)->render_texture (renderer, root, viewport);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user