diff options
author | Tomas Chvatal <scarabeus@gentoo.org> | 2011-02-25 19:10:37 +0000 |
---|---|---|
committer | Tomas Chvatal <scarabeus@gentoo.org> | 2011-02-25 19:10:37 +0000 |
commit | 55d688647774dcce86b8e13828010d490907604e (patch) | |
tree | e03edbe234426af9ce951a88b62facdbd2fa8985 /media-gfx/pornview | |
parent | Version bump. (diff) | |
download | gentoo-2-55d688647774dcce86b8e13828010d490907604e.tar.gz gentoo-2-55d688647774dcce86b8e13828010d490907604e.tar.bz2 gentoo-2-55d688647774dcce86b8e13828010d490907604e.zip |
Fix segmentation fault in comments and qa array boundaries warning.
(Portage version: 2.2.0_alpha25/cvs/Linux x86_64)
Diffstat (limited to 'media-gfx/pornview')
4 files changed, 58 insertions, 19 deletions
diff --git a/media-gfx/pornview/ChangeLog b/media-gfx/pornview/ChangeLog index 0d739f3d35cc..9cffd0222dd3 100644 --- a/media-gfx/pornview/ChangeLog +++ b/media-gfx/pornview/ChangeLog @@ -1,6 +1,12 @@ # ChangeLog for media-gfx/pornview -# Copyright 1999-2010 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/media-gfx/pornview/ChangeLog,v 1.36 2010/07/09 08:41:13 tove Exp $ +# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 +# $Header: /var/cvsroot/gentoo-x86/media-gfx/pornview/ChangeLog,v 1.37 2011/02/25 19:10:37 scarabeus Exp $ + + 25 Feb 2011; Tomáš Chvátal <scarabeus@gentoo.org> + pornview-0.2.0_pre1-r1.ebuild, + +files/pornview-0.2.0_pre1-fix-array-boundaries.patch, + +files/pornview-0.2.0_pre1-fix-segfault-comment.patch: + Fix segmentation fault in comments and qa array boundaries warning. 09 Jul 2010; Torsten Veller <tove@gentoo.org> metadata.xml: Update metadata.xml. antarus is staffer now (#119161) diff --git a/media-gfx/pornview/files/pornview-0.2.0_pre1-fix-array-boundaries.patch b/media-gfx/pornview/files/pornview-0.2.0_pre1-fix-array-boundaries.patch new file mode 100644 index 000000000000..918a3e2cfaa0 --- /dev/null +++ b/media-gfx/pornview/files/pornview-0.2.0_pre1-fix-array-boundaries.patch @@ -0,0 +1,13 @@ +diff --git a/pornview-0.2.0pre1.old/src/support/file_utils.c b/pornview-0.2.0pre1/src/support/file_utils.c +index fc88617..5eb7184 100644 +--- a/pornview-0.2.0pre1.old/src/support/file_utils.c ++++ b/pornview-0.2.0pre1/src/support/file_utils.c +@@ -787,7 +787,7 @@ gid2str (gid_t gid) + gchar * + mode2str (mode_t mode) + { +- gchar permission[11] = { "----------" }; ++ gchar permission[12] = { "----------" }; + + switch (mode & S_IFMT) + { diff --git a/media-gfx/pornview/files/pornview-0.2.0_pre1-fix-segfault-comment.patch b/media-gfx/pornview/files/pornview-0.2.0_pre1-fix-segfault-comment.patch new file mode 100644 index 000000000000..d1477e9b08e7 --- /dev/null +++ b/media-gfx/pornview/files/pornview-0.2.0_pre1-fix-segfault-comment.patch @@ -0,0 +1,20 @@ +diff -urN pornview-0.2.0pre1.old/src/comment.c pornview-0.2.0pre1/src/comment.c +--- pornview-0.2.0pre1.old/src/comment.c 2011-02-25 19:47:10.000000000 +0100 ++++ pornview-0.2.0pre1/src/comment.c 2011-02-25 20:05:43.000000000 +0100 +@@ -333,15 +333,7 @@ + entry->key = g_strdup (template->key); + entry->display_name = g_strdup (template->display_name); + +- if (comment->info && template->def_val_fn) +- { +- entry->value = entry->def_val_fn (comment->info, NULL); +- } +- else +- { +- entry->value = NULL; +- } +- ++ entry->value = NULL; + comment->data_list = g_list_append (comment->data_list, entry); + } + } diff --git a/media-gfx/pornview/pornview-0.2.0_pre1-r1.ebuild b/media-gfx/pornview/pornview-0.2.0_pre1-r1.ebuild index f8932270338c..e9bcc77a042d 100644 --- a/media-gfx/pornview/pornview-0.2.0_pre1-r1.ebuild +++ b/media-gfx/pornview/pornview-0.2.0_pre1-r1.ebuild @@ -1,6 +1,8 @@ -# Copyright 1999-2009 Gentoo Foundation +# Copyright 1999-2011 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -# $Header: /var/cvsroot/gentoo-x86/media-gfx/pornview/pornview-0.2.0_pre1-r1.ebuild,v 1.7 2009/09/28 23:40:36 vostorga Exp $ +# $Header: /var/cvsroot/gentoo-x86/media-gfx/pornview/pornview-0.2.0_pre1-r1.ebuild,v 1.8 2011/02/25 19:10:37 scarabeus Exp $ + +EAPI=4 inherit eutils toolchain-funcs @@ -11,11 +13,12 @@ SRC_URI="mirror://sourceforge/${PN}/${P/_/}.tar.gz" LICENSE="GPL-2" SLOT="0" KEYWORDS="amd64 -hppa ppc x86" -IUSE="jpeg nls mplayer" +IUSE="exif nls mplayer" RDEPEND="media-libs/libpng + virtual/jpeg mplayer? ( media-video/mplayer ) - jpeg? ( media-libs/jpeg ) + exif? ( media-gfx/exiv2 ) >=x11-libs/gtk+-2" DEPEND="${RDEPEND} dev-util/pkgconfig @@ -23,25 +26,22 @@ DEPEND="${RDEPEND} S=${WORKDIR}/${P/_/} -src_unpack() { - unpack ${A} - cd "${S}" +src_prepare() { epatch "${FILESDIR}"/${P}-4.diff \ "${FILESDIR}"/traypatch.diff \ "${FILESDIR}"/${P}-desktop-entry.patch \ - "${FILESDIR}"/${P}-new-gtk-object-system.diff + "${FILESDIR}"/${P}-new-gtk-object-system.diff \ + "${FILESDIR}"/${P}-fix-array-boundaries.patch \ + "${FILESDIR}"/${P}-fix-segfault-comment.patch } -src_compile() { - local myconf="--with-gtk2" - - use mplayer && myconf="${myconf} --enable-mplayer" - use jpeg || myconf="${myconf} --disable-exif" - use nls || myconf="${myconf} --disable-nls" - +src_configure() { tc-export CC - econf ${myconf} - emake || die "emake failed." + econf \ + --with-gtk2 \ + $(use_enable mplayer) \ + $(use_enable exif) \ + $(use_enable nls) } src_install() { |