Index: head/graphics/gdk-pixbuf/Makefile =================================================================== --- head/graphics/gdk-pixbuf/Makefile (revision 119690) +++ head/graphics/gdk-pixbuf/Makefile (revision 119691) @@ -1,39 +1,39 @@ # New ports collection makefile for: gdk-pixbuf # Date created: 5th October 1999 # Whom: Ade Lovett # # $FreeBSD$ # PORTNAME?= gdk-pixbuf PORTVERSION= 0.22.0 -PORTREVISION= 2 +PORTREVISION= 3 CATEGORIES?= graphics MASTER_SITES= ${MASTER_SITE_GNOME} MASTER_SITE_SUBDIR= sources/gdk-pixbuf/0.22 DISTNAME= gdk-pixbuf-${PORTVERSION} DIST_SUBDIR= gnome MAINTAINER= gnome@FreeBSD.org COMMENT?= A graphic library for GTK+ LIB_DEPENDS+= png.5:${PORTSDIR}/graphics/png \ tiff.4:${PORTSDIR}/graphics/tiff \ jpeg.9:${PORTSDIR}/graphics/jpeg USE_BZIP2= yes USE_GMAKE= yes USE_X_PREFIX= yes USE_GNOME+= gnomehack gtk12 INSTALLS_SHLIB= yes GNU_CONFIGURE= yes CONFIGURE_ARGS= --with-html-dir=${PREFIX}/share/doc \ --disable-gtk-doc CONFIGURE_ENV= CPPFLAGS="-I${LOCALBASE}/include" \ LIBS="-L${LOCALBASE}/lib" \ BUILD_CANVAS="${BUILD_CANVAS}" CONFIGURE_TARGET= --target=${MACHINE_ARCH}-unknown-freebsd${OSREL} BUILD_CANVAS?= no .include Property changes on: head/graphics/gdk-pixbuf/Makefile ___________________________________________________________________ Modified: cvs2svn:cvs-rev ## -1 +1 ## -1.42 \ No newline at end of property +1.43 \ No newline at end of property Index: head/graphics/gdk-pixbuf/files/patch-pixbuf-security =================================================================== --- head/graphics/gdk-pixbuf/files/patch-pixbuf-security (revision 119690) +++ head/graphics/gdk-pixbuf/files/patch-pixbuf-security (revision 119691) @@ -1,53 +1,41 @@ --- gdk-pixbuf/io-ico.c.orig Mon Oct 11 15:44:43 2004 +++ gdk-pixbuf/io-ico.c Mon Oct 11 15:47:29 2004 @@ -330,6 +330,10 @@ State->HeaderSize+=I; + if (State->HeaderSize < 0) { + return FALSE; + } + if (State->HeaderSize>State->BytesInHeaderBuf) { guchar *tmp=realloc(State->HeaderBuf,State->HeaderSize); if (!tmp) ---- gdk-pixbuf/io-xpm.c.orig Mon Oct 11 15:47:42 2004 -+++ gdk-pixbuf/io-xpm.c Mon Oct 11 16:01:13 2004 -@@ -352,16 +352,33 @@ +--- io-xpm.c.orig Thu Mar 1 15:16:28 2001 ++++ io-xpm.c Sun Oct 17 17:05:38 2004 +@@ -352,16 +352,21 @@ return NULL; } sscanf (buffer, "%d %d %d %d", &w, &h, &n_col, &cpp); - if (cpp >= 32) { - g_warning ("XPM has more than 31 chars per pixel."); + if (cpp <= 0 || cpp >= 32) { + g_warning ("XPM has invalid number of chars per pixel"); + return NULL; + } + + if (n_col <= 0 || n_col >= G_MAXINT / (cpp + 1)) { + g_warning ("XPM file has invalid number of colors"); return NULL; } /* The hash is used for fast lookups of color from chars */ color_hash = g_hash_table_new (g_str_hash, g_str_equal); - name_buf = g_new (gchar, n_col * (cpp + 1)); - colors = g_new (_XPMColor, n_col); -+ name_buf = (gchar *) g_try_malloc (n_col * (cpp + 1)); -+ if (!name_buf) { -+ g_warning ("Cannot allocate memory for loading XPM image"); -+ g_hash_table_destroy (color_hash); -+ return NULL; -+ } -+ -+ colors = (_XPMColor *) g_try_malloc (sizeof (_XPMColor) * n_col); -+ if (!colors) { -+ g_warning ("Cannot allocate memory for loading XPM image"); -+ g_hash_table_destroy (color_hash); -+ g_free (name_buf); -+ return NULL; -+ } ++ name_buf = (gchar *) g_malloc (n_col * (cpp + 1)); ++ colors = (_XPMColor *) g_malloc (sizeof (_XPMColor) * n_col); for (cnt = 0; cnt < n_col; cnt++) { gchar *color_name; Property changes on: head/graphics/gdk-pixbuf/files/patch-pixbuf-security ___________________________________________________________________ Modified: cvs2svn:cvs-rev ## -1 +1 ## -1.1 \ No newline at end of property +1.2 \ No newline at end of property