[gnome-photos/wip/rishi/unit-tests-gegl: 3/4] gegl: Be more strict about what is acceptable
- From: Debarshi Ray <debarshir src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-photos/wip/rishi/unit-tests-gegl: 3/4] gegl: Be more strict about what is acceptable
- Date: Wed, 28 Nov 2018 18:56:09 +0000 (UTC)
commit ad8952b2f1178dd887ae159b84cb6dcacbd0bd46
Author: Debarshi Ray <debarshir gnome org>
Date: Wed Nov 28 19:07:06 2018 +0100
gegl: Be more strict about what is acceptable
src/photos-gegl.c | 2 ++
1 file changed, 2 insertions(+)
---
diff --git a/src/photos-gegl.c b/src/photos-gegl.c
index 88a1092c..171d1a76 100644
--- a/src/photos-gegl.c
+++ b/src/photos-gegl.c
@@ -389,6 +389,8 @@ photos_gegl_buffer_new_from_pixbuf (GdkPixbuf *pixbuf)
gint width;
const guint8 *pixels;
+ g_return_val_if_fail (GDK_IS_PIXBUF (pixbuf), NULL);
+
height = gdk_pixbuf_get_height (pixbuf);
width = gdk_pixbuf_get_width (pixbuf);
gegl_rectangle_set (&bbox, 0, 0, (guint) width, (guint) height);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]