summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRomain Perier <mrpouet@gentoo.org>2009-07-04 13:41:43 +0000
committerRomain Perier <mrpouet@gentoo.org>2009-07-04 13:41:43 +0000
commitff1d5a3df221c8624e8a1cbad29b7fe3a1588fa9 (patch)
tree2dddb0d08e42f84e11bbc142d93bf169755187df /net-ftp/gftp
parentMarking audacity-1.3.7 ppc64 for bug 273094 (diff)
downloadgentoo-2-ff1d5a3df221c8624e8a1cbad29b7fe3a1588fa9.tar.gz
gentoo-2-ff1d5a3df221c8624e8a1cbad29b7fe3a1588fa9.tar.bz2
gentoo-2-ff1d5a3df221c8624e8a1cbad29b7fe3a1588fa9.zip
Fix SIGSEGV for gftp_expand_path function
(Portage version: 2.2_rc33/cvs/Linux x86_64)
Diffstat (limited to 'net-ftp/gftp')
-rw-r--r--net-ftp/gftp/ChangeLog10
-rw-r--r--net-ftp/gftp/files/gftp-2.0.19-gftp-expand-path-sigsegv.patch21
-rw-r--r--net-ftp/gftp/gftp-2.0.19-r1.ebuild41
3 files changed, 70 insertions, 2 deletions
diff --git a/net-ftp/gftp/ChangeLog b/net-ftp/gftp/ChangeLog
index fcf04241b65f..7587a375f99d 100644
--- a/net-ftp/gftp/ChangeLog
+++ b/net-ftp/gftp/ChangeLog
@@ -1,6 +1,12 @@
# ChangeLog for net-ftp/gftp
-# Copyright 2002-2009 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/net-ftp/gftp/ChangeLog,v 1.76 2009/02/07 21:12:17 armin76 Exp $
+# Copyright 1999-2009 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/net-ftp/gftp/ChangeLog,v 1.77 2009/07/04 13:41:43 mrpouet Exp $
+
+*gftp-2.0.19-r1 (04 Jul 2009)
+
+ 04 Jul 2009; Romain Perier <mrpouet@gentoo.org>
+ +gftp-2.0.19-r1.ebuild, +files/gftp-2.0.19-gftp-expand-path-sigsegv.patch:
+ Fix SIGSEGV for gftp_expand_path function
07 Feb 2009; Raúl Porcel <armin76@gentoo.org> gftp-2.0.19.ebuild:
sparc stable wrt #255853
diff --git a/net-ftp/gftp/files/gftp-2.0.19-gftp-expand-path-sigsegv.patch b/net-ftp/gftp/files/gftp-2.0.19-gftp-expand-path-sigsegv.patch
new file mode 100644
index 000000000000..f3e029dea0ca
--- /dev/null
+++ b/net-ftp/gftp/files/gftp-2.0.19-gftp-expand-path-sigsegv.patch
@@ -0,0 +1,21 @@
+Fix segmentation fault, when gftpui_run_chdir is called with directory=0x0,
+and then calls gftp_expand_path (src=0x0),
+the NULL string was cloned using g_strdup, which returns NULL if
+its only argument is NULL, then this returned string was unreferenced.
+
+ lib/misc.c | 2 ++
+ 1 files changed, 2 insertions(+), 0 deletions(-)
+
+diff --git a/lib/misc.c b/lib/misc.c
+index 16c019b..2791466 100644
+--- a/lib/misc.c
++++ b/lib/misc.c
+@@ -143,6 +143,8 @@ gftp_expand_path (gftp_request * request, const char *src)
+ tempchar;
+ struct passwd *pw;
+
++ g_return_val_if_fail(src != NULL, NULL);
++
+ pw = NULL;
+ str = g_strdup (src);
+
diff --git a/net-ftp/gftp/gftp-2.0.19-r1.ebuild b/net-ftp/gftp/gftp-2.0.19-r1.ebuild
new file mode 100644
index 000000000000..27b5d3d88543
--- /dev/null
+++ b/net-ftp/gftp/gftp-2.0.19-r1.ebuild
@@ -0,0 +1,41 @@
+# Copyright 1999-2009 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/net-ftp/gftp/gftp-2.0.19-r1.ebuild,v 1.1 2009/07/04 13:41:43 mrpouet Exp $
+
+inherit eutils
+
+DESCRIPTION="Gnome based FTP Client"
+SRC_URI="http://www.gftp.org/${P}.tar.bz2"
+HOMEPAGE="http://www.gftp.org"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
+IUSE="gtk ssl"
+
+RDEPEND=">=dev-libs/glib-2
+ sys-devel/gettext
+ sys-libs/ncurses
+ sys-libs/readline
+ gtk? ( >=x11-libs/gtk+-2 )
+ ssl? ( dev-libs/openssl )"
+DEPEND="${RDEPEND}
+ >=dev-util/pkgconfig-0.9"
+
+src_unpack() {
+ unpack ${A}
+ cd "${S}"
+
+ # Fix SIGSEGV for gftp_expand_path function
+ epatch "${FILESDIR}/${P}-${PN}-expand-path-sigsegv.patch"
+}
+
+src_compile() {
+ econf $(use_enable gtk gtkport) $(use_enable ssl) || die "configure failed"
+ emake || die "make failed"
+}
+
+src_install() {
+ emake DESTDIR="${D}" install || die "install failed"
+ dodoc ChangeLog* README* THANKS TODO docs/USERS-GUIDE || die "dodoc failed"
+}