summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJack Todaro <solpeth@posteo.org>2022-05-12 10:04:21 +1000
committerMike Gilbert <floppym@gentoo.org>2022-05-11 22:34:38 -0400
commit5ebd24e8a995df10e7873a8a81e78b0ae594347f (patch)
tree9b165db9fc0eab2b6dd04967f5a97c12f44f36af /sys-apps/dbus-broker
parentsys-apps/bubblewrap: Version bump to 0.6.2 (diff)
downloadgentoo-5ebd24e8a995df10e7873a8a81e78b0ae594347f.tar.gz
gentoo-5ebd24e8a995df10e7873a8a81e78b0ae594347f.tar.bz2
gentoo-5ebd24e8a995df10e7873a8a81e78b0ae594347f.zip
sys-apps/dbus-broker: bump up to 30
Also include upstream patch for runtime crash, https://github.com/bus1/dbus-broker/commit/608b259e25ef1348b9e4a8e022c35b5c68d3df98 Package-Manager: Portage-3.0.30, Repoman-3.0.3 Closes: https://github.com/gentoo/gentoo/pull/25450 Signed-off-by: Jack Todaro <solpeth@posteo.org> Signed-off-by: Mike Gilbert <floppym@gentoo.org>
Diffstat (limited to 'sys-apps/dbus-broker')
-rw-r--r--sys-apps/dbus-broker/Manifest1
-rw-r--r--sys-apps/dbus-broker/dbus-broker-30.ebuild45
-rw-r--r--sys-apps/dbus-broker/files/dbus-broker-30-user-free-assertion.patch64
3 files changed, 110 insertions, 0 deletions
diff --git a/sys-apps/dbus-broker/Manifest b/sys-apps/dbus-broker/Manifest
index 70747487a192..385f62db8178 100644
--- a/sys-apps/dbus-broker/Manifest
+++ b/sys-apps/dbus-broker/Manifest
@@ -6,3 +6,4 @@ DIST c-shquote-83ccc2893385fcca1424b188f0f6c45a62f2b38d.tar.gz 10622 BLAKE2B 1c7
DIST c-stdaux-8652c488b8f1c29629a5179d4551d0a691ae5901.tar.gz 13075 BLAKE2B ef08451574ea695151cbfdad2060324423c8abcf46ac8a86b3216b85017c9b4dd8399d0561cb4f2c731e9eb2883481db59292769560cbcbfc3e96823ceb70e9a SHA512 bb669b659955ea62734f401c9745059349b23e6ddbca56e72437929b9527647ff7ac6bba4bb06506e4d8d35f3a1e7c4eacd2d5b1e7cb21098faa144c932f2bb0
DIST c-utf8-0837214a9780b7d771a3b3ce9a49196ac0a9d52f.tar.gz 9340 BLAKE2B 4bfa39c39aa8db8b7d797d78081b5f3104c659e2ceefef65aa2d3c03ffb5889d772cb78328473e3557c943b2487b7bcb7b68d7dc7f2b95940b0448b3479f1b23 SHA512 2df368af5023fac6c7f2e018c0cbfd73225bf1c4e0d0387931352909323175652bcd3739e9e6b76a099aea5d3f0290198aa70c69ecc5e9ef22df214f8c75da79
DIST dbus-broker-29.tar.gz 216639 BLAKE2B 94c8b7ea01367eae176d9411af064a960a054d6fbeb2bdebe9ba983d0938443abeb521f32e0eb9ae28155d5c5ebcf461317223387ccfad624ddd24e6bc8e227b SHA512 4c31b8c15f5d1ada0eb9c63c905c9fc9b3b8336beb533974b9c2b2a6a89c306b77d029d1ddbccbad873f62cc0d02cc373a090907dd19eae1a8a7fc2e3a4c2113
+DIST dbus-broker-30.tar.xz 238688 BLAKE2B 716bdeac726e0168e09a5893f1906888c0dc63e4c5f377f2d5ba100f1a07da17bb0379053ac079e7c55e7af09c3d382368dd317df52e04eb0fe96af03aba7441 SHA512 8b7f614e18d15baa558de2c77fc65526011e75f9592d06ddb3cafa211ec9a1c45aa42a0e32122cb16bdfce8bc34407241080f37891fe5ccb6c4577f1cd4bc66c
diff --git a/sys-apps/dbus-broker/dbus-broker-30.ebuild b/sys-apps/dbus-broker/dbus-broker-30.ebuild
new file mode 100644
index 000000000000..6f7873290392
--- /dev/null
+++ b/sys-apps/dbus-broker/dbus-broker-30.ebuild
@@ -0,0 +1,45 @@
+# Copyright 2017-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit meson
+
+SRC_URI="https://github.com/bus1/${PN}/releases/download/v${PV}/${P}.tar.xz"
+DESCRIPTION="Linux D-Bus Message Broker"
+HOMEPAGE="https://github.com/bus1/dbus-broker/wiki"
+KEYWORDS="~amd64 ~arm64 ~ppc64 ~riscv"
+
+LICENSE="Apache-2.0"
+SLOT="0"
+IUSE="audit doc +launcher selinux"
+
+DEPEND="
+ audit? (
+ >=sys-process/audit-3.0
+ >=sys-libs/libcap-ng-0.6
+ )
+ launcher? (
+ >=dev-libs/expat-2.2
+ >=sys-apps/systemd-230:0=
+ )
+ selinux? ( >=sys-libs/libselinux-3.2 )
+"
+RDEPEND="${DEPEND}
+ launcher? ( sys-apps/dbus )"
+BDEPEND="
+ doc? ( dev-python/docutils )
+ virtual/pkgconfig
+"
+
+PATCHES=( "${FILESDIR}"/${P}-user-free-assertion.patch )
+
+src_configure() {
+ local emesonargs=(
+ -Daudit=$(usex audit true false)
+ -Ddocs=$(usex doc true false)
+ -Dlauncher=$(usex launcher true false)
+ -Dselinux=$(usex selinux true false)
+ )
+ meson_src_configure
+}
diff --git a/sys-apps/dbus-broker/files/dbus-broker-30-user-free-assertion.patch b/sys-apps/dbus-broker/files/dbus-broker-30-user-free-assertion.patch
new file mode 100644
index 000000000000..278de1821b87
--- /dev/null
+++ b/sys-apps/dbus-broker/files/dbus-broker-30-user-free-assertion.patch
@@ -0,0 +1,64 @@
+From 608b259e25ef1348b9e4a8e022c35b5c68d3df98 Mon Sep 17 00:00:00 2001
+From: David Rheinsberg <david.rheinsberg@gmail.com>
+Date: Wed, 11 May 2022 08:41:48 +0200
+Subject: [PATCH] util/user: keep reference to user in each usage table
+
+Keep a reference to an owning user in each usage table. We want to allow
+callers to hold charges without holding on to any user references.
+
+Also fix the peer-deinitialization to be ordered correctly and free the
+user references last (in particular, after the charges). This is not
+strictly necessary, but now follows our coding style and would have
+avoided possible failures.
+
+This fixes an assertion failure when disconnecting entire groups of
+peers of the same user, due to the recent fix that actually made
+peer-accounting do something.
+
+Reported-by: Torge Matthies
+Reported-by: Mel34
+Signed-off-by: David Rheinsberg <david.rheinsberg@gmail.com>
+---
+ src/bus/peer.c | 2 +-
+ src/util/user.c | 3 ++-
+ 2 files changed, 3 insertions(+), 2 deletions(-)
+
+diff --git a/src/bus/peer.c b/src/bus/peer.c
+index 18bd1947..69ed0fde 100644
+--- a/src/bus/peer.c
++++ b/src/bus/peer.c
+@@ -358,12 +358,12 @@ Peer *peer_free(Peer *peer) {
+ name_owner_deinit(&peer->owned_names);
+ policy_snapshot_free(peer->policy);
+ connection_deinit(&peer->connection);
+- user_unref(peer->user);
+ user_charge_deinit(&peer->charges[2]);
+ user_charge_deinit(&peer->charges[1]);
+ user_charge_deinit(&peer->charges[0]);
+ free(peer->seclabel);
+ free(peer->gids);
++ user_unref(peer->user);
+ free(peer);
+
+ close(fd);
+diff --git a/src/util/user.c b/src/util/user.c
+index 7856b768..d0edb5e8 100644
+--- a/src/util/user.c
++++ b/src/util/user.c
+@@ -48,7 +48,7 @@ static int user_usage_new(UserUsage **usagep, User *user, uid_t uid) {
+ return error_origin(-ENOMEM);
+
+ usage->n_refs = REF_INIT;
+- usage->user = user;
++ usage->user = user_ref(user);
+ usage->uid = uid;
+ usage->user_node = (CRBNode)C_RBNODE_INIT(usage->user_node);
+
+@@ -64,6 +64,7 @@ static void user_usage_free(_Atomic unsigned long *n_refs, void *userdata) {
+ c_assert(!usage->slots[i]);
+
+ user_usage_unlink(usage);
++ user_unref(usage->user);
+ free(usage);
+ }
+