File gdk-pixbuf-g_try_malloc.patch of Package gdk-pixbuf

2004-09-16  Manfred Hollstein  <manfred.hollstein@novell.com>

	* gdk-pixbuf/io-xpm.c (g_strlcpy, g_try_malloc, g_try_realloc): Add
	definitions for building with glib-1.2.x.

diff -rup gdk-pixbuf-0.22.0.orig/gdk-pixbuf/io-xpm.c gdk-pixbuf-0.22.0/gdk-pixbuf/io-xpm.c
--- gdk-pixbuf-0.22.0.orig/gdk-pixbuf/io-xpm.c	2004-09-16 10:08:31.673286232 +0200
+++ gdk-pixbuf-0.22.0/gdk-pixbuf/io-xpm.c	2004-09-16 10:05:17.669011008 +0200
@@ -36,6 +36,12 @@
 
 
 
+#if GLIB_MAJOR_VERSION < 2
+gsize g_strlcpy (gchar *dest, const gchar *src, gsize dest_size);
+#define g_try_malloc(x)		malloc(x)
+#define g_try_realloc(x)	realloc(x)
+#endif				/* GLIB_MAJOR_VERSION < 2 */
+
 /* I have must have done something to deserve this.
  * XPM is such a crappy format to handle.
  * This code is an ugly hybred from gdkpixmap.c
openSUSE Build Service is sponsored by