diff options
author | raveit65 <[email protected]> | 2014-04-21 12:15:04 +0200 |
---|---|---|
committer | raveit65 <[email protected]> | 2014-04-21 12:15:04 +0200 |
commit | 076f52594df5e68bf9806b4b69e915350b3c9319 (patch) | |
tree | e39cdd57c8d183db287d1a6cdde08d526ff10d2e /libdocument/ev-document-misc.c | |
parent | 256d520ce80c3adb6beb7156429610234bcadbe7 (diff) | |
download | atril-076f52594df5e68bf9806b4b69e915350b3c9319.tar.bz2 atril-076f52594df5e68bf9806b4b69e915350b3c9319.tar.xz |
create_thumbnail_frame should return NULL when
source_pixbuf is NULL and width and height are not positive.
fix https://bugzilla.redhat.com/show_bug.cgi?id=1082143
taken from https://git.gnome.org/browse/evince/commit/?id=3d8180a605e8c98172e9e0e739e22b7f50ed7bad
Diffstat (limited to 'libdocument/ev-document-misc.c')
-rw-r--r-- | libdocument/ev-document-misc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libdocument/ev-document-misc.c b/libdocument/ev-document-misc.c index d597127f..6099b7fa 100644 --- a/libdocument/ev-document-misc.c +++ b/libdocument/ev-document-misc.c @@ -56,7 +56,7 @@ create_thumbnail_frame (int width, } /* make sure no one is passing us garbage */ - g_assert (width_r >= 0 && height_r >= 0); + g_return_val_if_fail (width_r >= 0 && height_r >= 0, NULL); retval = gdk_pixbuf_new (GDK_COLORSPACE_RGB, TRUE, 8, |