diff options
author | Kirill Elagin <kirelagin@gmail.com> | 2011-10-04 23:02:20 +0400 |
---|---|---|
committer | Jeremy Huddleston <jeremyhu@apple.com> | 2011-10-09 01:35:49 -0700 |
commit | bec15eb73a17fb47963ff6b747ea504f7dc05deb (patch) | |
tree | e0f6fd0f529be819665f2e3c9cd5617f4a30acd1 /fb | |
parent | b45e22675364915c32560c26404cf30d77ab68aa (diff) |
Fix server crash due to invalid images
See https://bugs.freedesktop.org/show_bug.cgi?id=39383
Signed-off-by: Kirill Elagin <kirelagin@gmail.com>
Reviewed-by: Jeremy Huddleston <jeremyhu@apple.com>
(cherry picked from commit 53611213396479abfdce0f7752681572e0d26d78)
Diffstat (limited to 'fb')
-rw-r--r-- | fb/fbpict.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/fb/fbpict.c b/fb/fbpict.c index d1fd0cbbd..57c93fd06 100644 --- a/fb/fbpict.c +++ b/fb/fbpict.c @@ -163,7 +163,9 @@ create_bits_picture (PicturePtr pict, (pixman_format_code_t)pict->format, pixmap->drawable.width, pixmap->drawable.height, (uint32_t *)bits, stride * sizeof (FbStride)); - + + if (!image) + return NULL; #ifdef FB_ACCESS_WRAPPER #if FB_SHIFT==5 |