diff options
author | 2007-10-10 15:13:04 +0000 | |
---|---|---|
committer | 2007-10-10 15:13:04 +0000 | |
commit | ef7a334cf634fdfd2d440c8b0b4ff41233b45434 (patch) | |
tree | 175e0941a71636b41538fc837855ef6ad60b0d47 /media-libs/libpng | |
parent | x11-libs/gtksourceview: add version 2.0.0 in its own slot and change the slot... (diff) | |
download | gentoo-2-ef7a334cf634fdfd2d440c8b0b4ff41233b45434.tar.gz gentoo-2-ef7a334cf634fdfd2d440c8b0b4ff41233b45434.tar.bz2 gentoo-2-ef7a334cf634fdfd2d440c8b0b4ff41233b45434.zip |
Update the memory corruption bug in #194864
(Portage version: 2.1.3.12)
Diffstat (limited to 'media-libs/libpng')
-rw-r--r-- | media-libs/libpng/ChangeLog | 8 | ||||
-rw-r--r-- | media-libs/libpng/files/digest-libpng-1.2.21-r3 | 6 | ||||
-rw-r--r-- | media-libs/libpng/files/libpng-1.2.21-null-termination.patch | 27 | ||||
-rw-r--r-- | media-libs/libpng/libpng-1.2.21-r3.ebuild | 41 |
4 files changed, 81 insertions, 1 deletions
diff --git a/media-libs/libpng/ChangeLog b/media-libs/libpng/ChangeLog index 2877d584fc00..67fd6869efbf 100644 --- a/media-libs/libpng/ChangeLog +++ b/media-libs/libpng/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for media-libs/libpng # Copyright 1999-2007 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-libs/libpng/ChangeLog,v 1.153 2007/10/06 22:57:41 vapier Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-libs/libpng/ChangeLog,v 1.154 2007/10/10 15:13:04 cardoe Exp $ + +*libpng-1.2.21-r3 (10 Oct 2007) + + 10 Oct 2007; Doug Goldstein <cardoe@gentoo.org> + +files/libpng-1.2.21-null-termination.patch, +libpng-1.2.21-r3.ebuild: + Update the memory corruption bug in #194864 *libpng-1.2.21-r2 (06 Oct 2007) diff --git a/media-libs/libpng/files/digest-libpng-1.2.21-r3 b/media-libs/libpng/files/digest-libpng-1.2.21-r3 new file mode 100644 index 000000000000..5ef3058d09bf --- /dev/null +++ b/media-libs/libpng/files/digest-libpng-1.2.21-r3 @@ -0,0 +1,6 @@ +MD5 b0cda5e10e8165e5f151e674e1a67983 libpng-1.2.21.tar.bz2 614352 +RMD160 2738cb7cebe19184a0ffefe31c49e570b0791049 libpng-1.2.21.tar.bz2 614352 +SHA256 3b4f186e5dd1e683178d58d45db16f4fd9203f6518037ff28b4505ec35246953 libpng-1.2.21.tar.bz2 614352 +MD5 1518ec4b873f2c61a7d32ad867b67b17 libpng-manual.txt 128284 +RMD160 f019974f931327e6d9d332d306e07dce71ff031b libpng-manual.txt 128284 +SHA256 0cc3a25643024807672e5df255332cb63c902cea333246f4a5ab48c682c3297a libpng-manual.txt 128284 diff --git a/media-libs/libpng/files/libpng-1.2.21-null-termination.patch b/media-libs/libpng/files/libpng-1.2.21-null-termination.patch new file mode 100644 index 000000000000..96df6e0c9844 --- /dev/null +++ b/media-libs/libpng/files/libpng-1.2.21-null-termination.patch @@ -0,0 +1,27 @@ +--- libpng-1.2.21.orig/pngset.c 2007-10-07 16:56:56.062965000 -0500 ++++ libpng-1.2.21/pngset.c 2007-10-09 11:47:35.462755000 -0500 +@@ -689,9 +689,10 @@ + { + png_warning(png_ptr, "Insufficient memory to process iCCP chunk."); + return; + } +- png_strncpy(new_iccp_name, name, png_strlen(new_iccp_name)+1); ++ png_strncpy(new_iccp_name, name, png_strlen(name)); ++ new_iccp_name[png_strlen(name)] = '\0'; + new_iccp_profile = (png_charp)png_malloc_warn(png_ptr, proflen); + if (new_iccp_profile == NULL) + { + png_free (png_ptr, new_iccp_name); +@@ -979,9 +980,10 @@ + png_warning(png_ptr, + "Out of memory while processing sPLT chunk"); + } + /* TODO: use png_malloc_warn */ +- png_strncpy(to->name, from->name, png_strlen(from->name)+1); ++ png_strncpy(to->name, from->name, png_strlen(from->name)); ++ to->name[png_strlen(from->name)] = '\0'; + to->entries = (png_sPLT_entryp)png_malloc_warn(png_ptr, + from->nentries * png_sizeof(png_sPLT_entry)); + /* TODO: use png_malloc_warn */ + png_memcpy(to->entries, from->entries, + diff --git a/media-libs/libpng/libpng-1.2.21-r3.ebuild b/media-libs/libpng/libpng-1.2.21-r3.ebuild new file mode 100644 index 000000000000..5ff80fa34db0 --- /dev/null +++ b/media-libs/libpng/libpng-1.2.21-r3.ebuild @@ -0,0 +1,41 @@ +# Copyright 1999-2007 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/media-libs/libpng/libpng-1.2.21-r3.ebuild,v 1.1 2007/10/10 15:13:04 cardoe Exp $ + +inherit libtool multilib eutils flag-o-matic + +DESCRIPTION="Portable Network Graphics library" +HOMEPAGE="http://www.libpng.org/" +SRC_URI="mirror://sourceforge/libpng/${P}.tar.bz2 + doc? ( http://www.libpng.org/pub/png/libpng-manual.txt )" + +LICENSE="as-is" +SLOT="1.2" +KEYWORDS="~alpha ~amd64 ~arm ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~sparc-fbsd ~x86 ~x86-fbsd" +IUSE="doc" + +DEPEND="sys-libs/zlib" + +src_unpack() { + unpack ${A} + cd "${S}" + use doc && cp "${WORKDIR}"/${PN}-manual.txt . + epatch "${FILESDIR}"/1.2.7-gentoo.diff + epatch "${FILESDIR}"/${P}-null-termination.patch #194864 + + # So we get sane .so versioning on FreeBSD + elibtoolize +} + +src_install() { + emake DESTDIR="${D}" install || die + dodoc ANNOUNCE CHANGES KNOWNBUG README TODO Y2KINFO + use doc && dodoc libpng-manual.txt +} + +pkg_postinst() { + # the libpng authors really screwed around between 1.2.1 and 1.2.3 + if [[ -f ${ROOT}/usr/$(get_libdir)/libpng.so.3.1.2.1 ]] ; then + rm -f "${ROOT}"/usr/$(get_libdir)/libpng.so.3.1.2.1 + fi +} |