summaryrefslogtreecommitdiff
path: root/gtk/gtkpixmap.c
diff options
context:
space:
mode:
Diffstat (limited to 'gtk/gtkpixmap.c')
-rw-r--r--gtk/gtkpixmap.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gtk/gtkpixmap.c b/gtk/gtkpixmap.c
index e9680d2eb3..0b1d48261e 100644
--- a/gtk/gtkpixmap.c
+++ b/gtk/gtkpixmap.c
@@ -131,7 +131,8 @@ gtk_pixmap_set (GtkPixmap *pixmap,
gint oldheight;
g_return_if_fail (GTK_IS_PIXMAP (pixmap));
- g_return_if_fail (gdk_colormap_get_visual (gtk_widget_get_colormap (GTK_WIDGET (pixmap)))->depth == gdk_drawable_get_depth (GDK_DRAWABLE (val)));
+ if(GDK_IS_DRAWABLE(val))
+ g_return_if_fail (gdk_colormap_get_visual (gtk_widget_get_colormap (GTK_WIDGET (pixmap)))->depth == gdk_drawable_get_depth (GDK_DRAWABLE (val)));
if (pixmap->pixmap != val)
{