shell-util: ensure we've a valid n_captures when capturing images

https://bugzilla.gnome.org/show_bug.cgi?id=765011
This commit is contained in:
Marco Trevisan (Treviño) 2017-06-08 20:16:04 +08:00 committed by Jonas Ådahl
parent b099e9a69c
commit 4c2fd513f4

View File

@ -461,6 +461,8 @@ shell_util_composite_capture_images (ClutterCapture *captures,
cairo_surface_t *image; cairo_surface_t *image;
cairo_t *cr; cairo_t *cr;
g_assert (n_captures > 0);
target_scale = 0.0; target_scale = 0.0;
for (i = 0; i < n_captures; i++) for (i = 0; i < n_captures; i++)
{ {