From 34d6cc9e837f99b01d90b27d94040a98db410e4c Mon Sep 17 00:00:00 2001 From: Sven Neumann Date: Mon, 28 Mar 2005 00:11:43 +0000 Subject: [PATCH] handle gimp_viewable_get_pixbuf() returning NULL. Fixes bug #171827. 2005-03-28 Sven Neumann * app/dialogs/resize-dialog.c (resize_dialog_new): handle gimp_viewable_get_pixbuf() returning NULL. Fixes bug #171827. --- ChangeLog | 5 +++++ app/dialogs/resize-dialog.c | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 439c81b75d..6df82008fa 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2005-03-28 Sven Neumann + + * app/dialogs/resize-dialog.c (resize_dialog_new): handle + gimp_viewable_get_pixbuf() returning NULL. Fixes bug #171827. + 2005-03-26 Michael Natterer * plug-ins/script-fu/script-fu-scripts.c (script_fu_find_scripts): diff --git a/app/dialogs/resize-dialog.c b/app/dialogs/resize-dialog.c index dd0843c5aa..8415da0258 100644 --- a/app/dialogs/resize-dialog.c +++ b/app/dialogs/resize-dialog.c @@ -261,7 +261,8 @@ resize_dialog_new (GimpViewable *viewable, gimp_viewable_get_preview_size (viewable, 200, FALSE, TRUE, &width, &height); pixbuf = gimp_viewable_get_pixbuf (viewable, width, height); - gimp_offset_area_set_pixbuf (GIMP_OFFSET_AREA (private->area), pixbuf); + if (pixbuf) + gimp_offset_area_set_pixbuf (GIMP_OFFSET_AREA (private->area), pixbuf); g_signal_connect (private->area, "offsets_changed", G_CALLBACK (offsets_changed),