diff options
author | Joe Marcus Clarke <marcus@FreeBSD.org> | 2004-10-17 21:08:40 +0000 |
---|---|---|
committer | Joe Marcus Clarke <marcus@FreeBSD.org> | 2004-10-17 21:08:40 +0000 |
commit | ca8f1390f3b9faa879f9fefda0c2c8240a3eb992 (patch) | |
tree | 24148bc32cab5e62f5930bc5026e6c65a796833f | |
parent | 25b45a3429c9fe1b758f45c7d3ce66ce9ec8f287 (diff) | |
download | ports-ca8f1390f3b9faa879f9fefda0c2c8240a3eb992.tar.gz ports-ca8f1390f3b9faa879f9fefda0c2c8240a3eb992.zip |
Notes
-rw-r--r-- | graphics/gdk-pixbuf/Makefile | 2 | ||||
-rw-r--r-- | graphics/gdk-pixbuf/files/patch-pixbuf-security | 22 |
2 files changed, 6 insertions, 18 deletions
diff --git a/graphics/gdk-pixbuf/Makefile b/graphics/gdk-pixbuf/Makefile index 131e45cab78a..e80d9a3cad39 100644 --- a/graphics/gdk-pixbuf/Makefile +++ b/graphics/gdk-pixbuf/Makefile @@ -7,7 +7,7 @@ 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 diff --git a/graphics/gdk-pixbuf/files/patch-pixbuf-security b/graphics/gdk-pixbuf/files/patch-pixbuf-security index 44c4eb8da4b9..cae13c9d432a 100644 --- a/graphics/gdk-pixbuf/files/patch-pixbuf-security +++ b/graphics/gdk-pixbuf/files/patch-pixbuf-security @@ -11,9 +11,9 @@ 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); @@ -34,20 +34,8 @@ - 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; |