public inbox for gentoo-commits@lists.gentoo.org
 help / color / mirror / Atom feed
From: "Lars Wendler" <polynomial-c@gentoo.org>
To: gentoo-commits@lists.gentoo.org
Subject: [gentoo-commits] repo/gentoo:master commit in: media-plugins/alsa-plugins/files/, media-plugins/alsa-plugins/
Date: Fri,  4 Jan 2019 17:47:40 +0000 (UTC)	[thread overview]
Message-ID: <1546624033.c34bd91f35dce053ca34d24712c227c0db833f5e.polynomial-c@gentoo> (raw)

commit:     c34bd91f35dce053ca34d24712c227c0db833f5e
Author:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
AuthorDate: Fri Jan  4 17:47:13 2019 +0000
Commit:     Lars Wendler <polynomial-c <AT> gentoo <DOT> org>
CommitDate: Fri Jan  4 17:47:13 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c34bd91f

media-plugins/alsa-plugins: Fixed a double free issue.

Closes: https://bugs.gentoo.org/673792
Package-Manager: Portage-2.3.54, Repoman-2.3.12
Signed-off-by: Lars Wendler <polynomial-c <AT> gentoo.org>

 ...s-1.1.7.ebuild => alsa-plugins-1.1.7-r1.ebuild} |  6 +++-
 .../files/alsa-plugins-1.1.7-double_free_fix.patch | 34 ++++++++++++++++++++++
 2 files changed, 39 insertions(+), 1 deletion(-)

diff --git a/media-plugins/alsa-plugins/alsa-plugins-1.1.7.ebuild b/media-plugins/alsa-plugins/alsa-plugins-1.1.7-r1.ebuild
similarity index 96%
rename from media-plugins/alsa-plugins/alsa-plugins-1.1.7.ebuild
rename to media-plugins/alsa-plugins/alsa-plugins-1.1.7-r1.ebuild
index 2eff3aacc81..f97cc166249 100644
--- a/media-plugins/alsa-plugins/alsa-plugins-1.1.7.ebuild
+++ b/media-plugins/alsa-plugins/alsa-plugins-1.1.7-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2018 Gentoo Authors
+# Copyright 1999-2019 Gentoo Authors
 # Distributed under the terms of the GNU General Public License v2
 
 EAPI=7
@@ -30,6 +30,10 @@ RDEPEND="
 DEPEND="${RDEPEND}"
 BDEPEND="virtual/pkgconfig"
 
+PATCHES=(
+	"${FILESDIR}"/${P}-double_free_fix.patch
+)
+
 src_prepare() {
 	default
 

diff --git a/media-plugins/alsa-plugins/files/alsa-plugins-1.1.7-double_free_fix.patch b/media-plugins/alsa-plugins/files/alsa-plugins-1.1.7-double_free_fix.patch
new file mode 100644
index 00000000000..9b3a81599b3
--- /dev/null
+++ b/media-plugins/alsa-plugins/files/alsa-plugins-1.1.7-double_free_fix.patch
@@ -0,0 +1,34 @@
+From a4e7e1282c57a2f4e83afe9a4008042d8b4c5bb9 Mon Sep 17 00:00:00 2001
+From: Jaroslav Kysela <perex@perex.cz>
+Date: Tue, 23 Oct 2018 09:32:46 +0200
+Subject: [PATCH] a52_close: set slave to NULL to avoid double pcm free in
+ open fcn
+
+Signed-off-by: Jaroslav Kysela <perex@perex.cz>
+---
+ a52/pcm_a52.c | 7 +++++--
+ 1 file changed, 5 insertions(+), 2 deletions(-)
+
+diff --git a/a52/pcm_a52.c b/a52/pcm_a52.c
+index e431fd0..b005bc2 100644
+--- a/a52/pcm_a52.c
++++ b/a52/pcm_a52.c
+@@ -654,10 +654,13 @@ static int a52_poll_revents(snd_pcm_ioplug_t *io, struct pollfd *pfd,
+ static int a52_close(snd_pcm_ioplug_t *io)
+ {
+ 	struct a52_ctx *rec = io->private_data;
++	snd_pcm_t *slave = rec->slave;
+ 
+ 	a52_free(rec);
+-	if (rec->slave)
+-		return snd_pcm_close(rec->slave);
++	if (slave) {
++		rec->slave = NULL;
++		return snd_pcm_close(slave);
++	}
+ 	return 0;
+ }
+ 			      
+-- 
+1.7.11.7
+


             reply	other threads:[~2019-01-04 17:47 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-01-04 17:47 Lars Wendler [this message]
  -- strict thread matches above, loose matches on Subject: below --
2025-06-03  4:41 [gentoo-commits] repo/gentoo:master commit in: media-plugins/alsa-plugins/files/, media-plugins/alsa-plugins/ Sam James
2020-02-20 15:49 Lars Wendler
2019-11-16 13:06 Lars Wendler
2017-05-18 11:44 Lars Wendler
2016-03-31 20:30 Lars Wendler
2015-09-14 15:50 Alexis Ballier

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1546624033.c34bd91f35dce053ca34d24712c227c0db833f5e.polynomial-c@gentoo \
    --to=polynomial-c@gentoo.org \
    --cc=gentoo-commits@lists.gentoo.org \
    --cc=gentoo-dev@lists.gentoo.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox