From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) by finch.gentoo.org (Postfix) with ESMTP id 495501393F1 for ; Mon, 14 Sep 2015 19:40:29 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id 0C88221C035; Mon, 14 Sep 2015 19:40:28 +0000 (UTC) Received: from smtp.gentoo.org (smtp.gentoo.org [140.211.166.183]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 8BE9521C035 for ; Mon, 14 Sep 2015 19:40:27 +0000 (UTC) Received: from oystercatcher.gentoo.org (unknown [IPv6:2a01:4f8:202:4333:225:90ff:fed9:fc84]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id 28204340B53 for ; Mon, 14 Sep 2015 19:40:25 +0000 (UTC) Received: from localhost.localdomain (localhost [127.0.0.1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 607D8189 for ; Mon, 14 Sep 2015 19:40:23 +0000 (UTC) From: "Ian Stakenvicius" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Ian Stakenvicius" Message-ID: <1442259584.e44233b3de61851f504ee94f8b2c526d6ec200af.axs@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: x11-misc/slim/files/, x11-misc/slim/ X-VCS-Repository: repo/gentoo X-VCS-Files: x11-misc/slim/files/slim-1.3.6-envcpy-bad-pointer-arithmetic.patch x11-misc/slim/slim-1.3.6-r4.ebuild x11-misc/slim/slim-1.3.6-r5.ebuild X-VCS-Directories: x11-misc/slim/files/ x11-misc/slim/ X-VCS-Committer: axs X-VCS-Committer-Name: Ian Stakenvicius X-VCS-Revision: e44233b3de61851f504ee94f8b2c526d6ec200af X-VCS-Branch: master Date: Mon, 14 Sep 2015 19:40:23 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Archives-Salt: c9e3a06a-4d14-44ae-90d4-826db437bc9d X-Archives-Hash: e46b30d7552e932f187776a0e5674b9b commit: e44233b3de61851f504ee94f8b2c526d6ec200af Author: Ian Stakenvicius gentoo org> AuthorDate: Mon Sep 14 19:30:37 2015 +0000 Commit: Ian Stakenvicius gentoo org> CommitDate: Mon Sep 14 19:39:44 2015 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e44233b3 x11-misc/slim: fix pointer arithmetic error While addressing bug 560088 related to consolekit-1.0, it was found that some pointer arithmetic being used in a malloc and memcpy was wrong and was causing a malloc corruption error. This patch addresses the out-of-bounds indexing. Package-Manager: portage-2.2.20.1 .../slim-1.3.6-envcpy-bad-pointer-arithmetic.patch | 15 +++++++++++++ .../{slim-1.3.6-r4.ebuild => slim-1.3.6-r5.ebuild} | 25 +++++++++++----------- 2 files changed, 28 insertions(+), 12 deletions(-) diff --git a/x11-misc/slim/files/slim-1.3.6-envcpy-bad-pointer-arithmetic.patch b/x11-misc/slim/files/slim-1.3.6-envcpy-bad-pointer-arithmetic.patch new file mode 100644 index 0000000..b3787dd --- /dev/null +++ b/x11-misc/slim/files/slim-1.3.6-envcpy-bad-pointer-arithmetic.patch @@ -0,0 +1,15 @@ +--- a/app.cpp 2015-09-14 12:00:00.460481656 -0400 ++++ b/app.cpp 2015-09-14 14:41:10.970536588 -0400 +@@ -606,9 +606,9 @@ + + n++; + +- child_env = static_cast(malloc(sizeof(char*)*n)); +- memcpy(child_env, old_env, sizeof(char*)*n+1); +- child_env[n - 1] = StrConcat("XDG_SESSION_COOKIE=", ck.get_xdg_session_cookie()); ++ child_env = static_cast(malloc(sizeof(char*)*(n+1))); ++ memcpy(child_env, old_env, sizeof(char*)*n); ++ child_env[n-1] = StrConcat("XDG_SESSION_COOKIE=", ck.get_xdg_session_cookie()); + child_env[n] = NULL; + } + # endif /* USE_CONSOLEKIT */ diff --git a/x11-misc/slim/slim-1.3.6-r4.ebuild b/x11-misc/slim/slim-1.3.6-r5.ebuild similarity index 84% rename from x11-misc/slim/slim-1.3.6-r4.ebuild rename to x11-misc/slim/slim-1.3.6-r5.ebuild index 728b2f4..2fdeebe 100644 --- a/x11-misc/slim/slim-1.3.6-r4.ebuild +++ b/x11-misc/slim/slim-1.3.6-r5.ebuild @@ -1,4 +1,4 @@ -# Copyright 1999-2014 Gentoo Foundation +# Copyright 1999-2015 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 # $Id$ @@ -36,17 +36,18 @@ PDEPEND="branding? ( >=x11-themes/slim-themes-1.2.3a-r3 )" src_prepare() { # Our Gentoo-specific config changes - epatch "${FILESDIR}"/${P}-config.diff - epatch "${FILESDIR}"/${PN}-1.3.5-arm.patch - epatch "${FILESDIR}"/${P}-honour-cflags.patch - epatch "${FILESDIR}"/${P}-libslim-cmake-fixes.patch - epatch "${FILESDIR}"/${PN}-1.3.5-disable-ck-for-systemd.patch - epatch "${FILESDIR}"/${P}-strip-systemd-unit-install.patch - epatch "${FILESDIR}"/${P}-systemd-session.patch - epatch "${FILESDIR}"/${P}-session-chooser.patch - epatch "${FILESDIR}"/${P}-fix-slimlock-nopam-v2.patch - epatch "${FILESDIR}"/${P}-drop-zlib.patch - epatch "${FILESDIR}"/${P}-freetype.patch + epatch "${FILESDIR}"/${P}-config.diff \ + "${FILESDIR}"/${PN}-1.3.5-arm.patch \ + "${FILESDIR}"/${P}-honour-cflags.patch \ + "${FILESDIR}"/${P}-libslim-cmake-fixes.patch \ + "${FILESDIR}"/${PN}-1.3.5-disable-ck-for-systemd.patch \ + "${FILESDIR}"/${P}-strip-systemd-unit-install.patch \ + "${FILESDIR}"/${P}-systemd-session.patch \ + "${FILESDIR}"/${P}-session-chooser.patch \ + "${FILESDIR}"/${P}-fix-slimlock-nopam-v2.patch \ + "${FILESDIR}"/${P}-drop-zlib.patch \ + "${FILESDIR}"/${P}-freetype.patch \ + "${FILESDIR}"/${P}-envcpy-bad-pointer-arithmetic.patch if use elibc_FreeBSD; then sed -i -e 's/"-DHAVE_SHADOW"/"-DNEEDS_BASENAME"/' CMakeLists.txt \