On Mon, Jun 06, 2005 at 03:52:32PM +0100, y g wrote: > I already did as I realised that neither is a child of the other as > you say. But I am still get seg fault with the following: > > static void > save_image(GtkWidget* widget, gpointer user_data) > { > GdkPixbuf* pixbuf; > > g_print("Saving image...\n"); > //gdk_pixbuf_save(gdk_pixbuf_get_from_drawable(NULL, > GDK_DRAWABLE(pixmap), NULL, 0, 0, 0, 0, 600, 400), "temp.bmp", "bmp", > NULL); > gdk_pixbuf_get_from_drawable(pixbuf, GDK_DRAWABLE(pixmap), NULL, 0,
Here you pass an uninitialized pointer as pixbuf... > 0, 0, 0, 600, 400); > gdk_pixbuf_save(pixbuf, "temp.bmp", "bmp", NULL); ...and again. Don't you get any CRITICAL messages to console? pixbuf = gdk_pixbuf_get_from_drawable(NULL, drawable, ...); gdk_pixbuf_save(pixbuf, ...); g_object_unref(pixbuf); Yeti -- A: Because it messes up the order in which people normally read text. Q: Why is top-posting such a bad thing? A: Top-posting. Q: What is the most annoying thing on usenet and in e-mail? _______________________________________________ gtk-app-devel-list mailing list gtk-app-devel-list@gnome.org http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list