diff options
-rw-r--r-- | dev-libs/librelp/ChangeLog | 12 | ||||
-rw-r--r-- | dev-libs/librelp/files/librelp-1.2.7-prevent-segfault-with-keepalive.patch | 32 | ||||
-rw-r--r-- | dev-libs/librelp/librelp-1.2.7-r1.ebuild | 44 |
3 files changed, 87 insertions, 1 deletions
diff --git a/dev-libs/librelp/ChangeLog b/dev-libs/librelp/ChangeLog index fbc6895d1548..b72547054a5d 100644 --- a/dev-libs/librelp/ChangeLog +++ b/dev-libs/librelp/ChangeLog @@ -1,6 +1,16 @@ # ChangeLog for dev-libs/librelp # Copyright 1999-2014 Gentoo Foundation; Distributed under the GPL v2 -# $Header: /var/cvsroot/gentoo-x86/dev-libs/librelp/ChangeLog,v 1.26 2014/05/04 14:17:14 ultrabug Exp $ +# $Header: /var/cvsroot/gentoo-x86/dev-libs/librelp/ChangeLog,v 1.27 2014/07/05 08:02:24 dev-zero Exp $ + +*librelp-1.2.7-r1 (05 Jul 2014) + + 05 Jul 2014; Tiziano Müller <dev-zero@gentoo.org> + +files/librelp-1.2.7-prevent-segfault-with-keepalive.patch, + +librelp-1.2.7-r1.ebuild: + Always DEPEND on gnutls for the headers (bug #513754), only RDEPEND for gnutls + depends now on the flag. Add a patch from upstream to prevent segfaults with + keepalive. Use autotools-utils eclass for src_install (solves bug #475012 + properly). *librelp-1.2.7 (04 May 2014) diff --git a/dev-libs/librelp/files/librelp-1.2.7-prevent-segfault-with-keepalive.patch b/dev-libs/librelp/files/librelp-1.2.7-prevent-segfault-with-keepalive.patch new file mode 100644 index 000000000000..2f9803d0d8a8 --- /dev/null +++ b/dev-libs/librelp/files/librelp-1.2.7-prevent-segfault-with-keepalive.patch @@ -0,0 +1,32 @@ +From 0ca7f807958e8365b2fd2f3fd833814c83594bdc Mon Sep 17 00:00:00 2001 +From: Tomas Heinrich <theinric@redhat.com> +Date: Sun, 1 Jun 2014 16:44:59 +0200 +Subject: [PATCH] Reorder code, prevent access of uninitialized data + +--- + src/tcp.c | 6 +++--- + 1 file changed, 3 insertions(+), 3 deletions(-) + +diff --git a/src/tcp.c b/src/tcp.c +index 1e0fd11..e21db51 100644 +--- a/src/tcp.c ++++ b/src/tcp.c +@@ -713,12 +713,12 @@ relpTcpAcceptConnReq(relpTcp_t **ppThis, int sock, relpSrv_t *pSrv) + ABORT_FINALIZE(RELP_RET_ACCEPT_ERR); + } + +- if(pSrv->bKeepAlive) +- EnableKeepAlive(pThis, pSrv, iNewSock); +- + /* construct our object so that we can use it... */ + CHKRet(relpTcpConstruct(&pThis, pEngine, RELP_SRV_CONN, pSrv)); + ++ if(pSrv->bKeepAlive) ++ EnableKeepAlive(pThis, pSrv, iNewSock); ++ + /* TODO: obtain hostname, normalize (callback?), save it */ + CHKRet(relpTcpSetRemHost(pThis, (struct sockaddr*) &addr)); + pThis->pEngine->dbgprint("remote host is '%s', ip '%s'\n", pThis->pRemHostName, pThis->pRemHostIP); +-- +1.9.3 + diff --git a/dev-libs/librelp/librelp-1.2.7-r1.ebuild b/dev-libs/librelp/librelp-1.2.7-r1.ebuild new file mode 100644 index 000000000000..5a62a5b0393e --- /dev/null +++ b/dev-libs/librelp/librelp-1.2.7-r1.ebuild @@ -0,0 +1,44 @@ +# Copyright 1999-2014 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 +# $Header: /var/cvsroot/gentoo-x86/dev-libs/librelp/librelp-1.2.7-r1.ebuild,v 1.1 2014/07/05 08:02:24 dev-zero Exp $ + +EAPI=5 + +inherit autotools-utils + +DESCRIPTION="An easy to use library for the RELP protocol." +HOMEPAGE="http://www.librelp.com/" +SRC_URI="http://download.rsyslog.com/${PN}/${P}.tar.gz" + +LICENSE="GPL-3 doc? ( FDL-1.3 )" +SLOT="0" +KEYWORDS="~amd64 ~arm ~hppa ~sparc ~x86" +IUSE="debug doc +ssl static-libs" + +RDEPEND=" + ssl? ( >=net-libs/gnutls-2.12.23-r1 ) +" + +DEPEND=" + >=net-libs/gnutls-2.12.23-r1 + virtual/pkgconfig +" + +AUTOTOOLS_IN_SOURCE_BUILD=1 + +PATCHES=( "${FILESDIR}/${P}-prevent-segfault-with-keepalive.patch" ) + +src_configure() { + # gnutls-headers are always required (in src/tcp.h) despite the flag, bug #513754 + local myeconfargs=( + $(use_enable debug) + $(use_enable ssl tls) + ) + + autotools-utils_src_configure +} + +src_install() { + use doc && HTML_DOCS=( doc/relp.html ) + autotools-utils_src_install +} |