thumbnails: do not crash if window size is 0x0

This commit is contained in:
Chris Lee 2019-02-23 22:49:58 +01:00
parent 77890d463a
commit 4dafea185f

View file

@ -414,6 +414,8 @@ cairo_surface_t *get_window_thumbnail_ximage(Window win, size_t size, gboolean u
fw = tw;
ox = oy = 0;
}
if (!w || !h || !tw || !th || !fw)
goto err0;
XShmSegmentInfo shminfo;
XImage *ximg;