summaryrefslogtreecommitdiff
path: root/gdk-pixbuf/gdk-pixbuf-io.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdk-pixbuf/gdk-pixbuf-io.c')
-rw-r--r--gdk-pixbuf/gdk-pixbuf-io.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gdk-pixbuf/gdk-pixbuf-io.c b/gdk-pixbuf/gdk-pixbuf-io.c
index 1dbbd26cf..0770962d0 100644
--- a/gdk-pixbuf/gdk-pixbuf-io.c
+++ b/gdk-pixbuf/gdk-pixbuf-io.c
@@ -975,6 +975,9 @@ size_prepared_cb (GdkPixbufLoader *loader,
height = info->height;
}
+ width = MAX (width, 1);
+ height = MAX (height, 1);
+
gdk_pixbuf_loader_set_size (loader, width, height);
}