Check for background image allocation failure
This commit is contained in:
parent
4fde8c8cbc
commit
d049391916
2
Makefile
2
Makefile
@ -1,4 +1,4 @@
|
|||||||
VERSION = git-20140206
|
VERSION = git-20140207
|
||||||
|
|
||||||
PREFIX = /usr/local
|
PREFIX = /usr/local
|
||||||
MANPREFIX = $(PREFIX)/share/man
|
MANPREFIX = $(PREFIX)/share/man
|
||||||
|
3
image.c
3
image.c
@ -492,7 +492,8 @@ void img_render(img_t *img)
|
|||||||
imlib_context_set_drawable(win->pm);
|
imlib_context_set_drawable(win->pm);
|
||||||
|
|
||||||
if (imlib_image_has_alpha()) {
|
if (imlib_image_has_alpha()) {
|
||||||
bg = imlib_create_image(dw, dh);
|
if ((bg = imlib_create_image(dw, dh)) == NULL)
|
||||||
|
die("could not allocate memory");
|
||||||
imlib_context_set_image(bg);
|
imlib_context_set_image(bg);
|
||||||
imlib_image_set_has_alpha(0);
|
imlib_image_set_has_alpha(0);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user