From 3898d404857d99c5e83d3d10c0844f6d7c06f3ae Mon Sep 17 00:00:00 2001 From: Simon McVittie Date: Fri, 11 May 2018 18:11:06 +0100 Subject: [PATCH 10/39] bus_activation_list_services: Take the DBusConnection that wants to know This will be necessary when we give connections from containers a different answer that only lists a subset of the names. Signed-off-by: Simon McVittie --- bus/activation.c | 3 ++- bus/activation.h | 3 ++- bus/driver.c | 2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/bus/activation.c b/bus/activation.c index ee0018c1..4e785319 100644 --- a/bus/activation.c +++ b/bus/activation.c @@ -2356,7 +2356,8 @@ cancel_pending_activation: dbus_bool_t bus_activation_list_services (BusActivation *activation, char ***listp, - int *array_len) + int *array_len, + DBusConnection *observer) { int i, j, len; char **retval; diff --git a/bus/activation.h b/bus/activation.h index 7ae8ade9..f5edf416 100644 --- a/bus/activation.h +++ b/bus/activation.h @@ -56,7 +56,8 @@ dbus_bool_t bus_activation_service_created (BusActivation *activation, DBusError *error); dbus_bool_t bus_activation_list_services (BusActivation *registry, char ***listp, - int *array_len); + int *array_len, + DBusConnection *observer); dbus_bool_t dbus_activation_systemd_failure (BusActivation *activation, DBusMessage *message); diff --git a/bus/driver.c b/bus/driver.c index e9342010..0acbef5c 100644 --- a/bus/driver.c +++ b/bus/driver.c @@ -701,7 +701,7 @@ bus_driver_handle_list_activatable_services (DBusConnection *connection, return FALSE; } - if (!bus_activation_list_services (activation, &services, &len)) + if (!bus_activation_list_services (activation, &services, &len, connection)) { dbus_message_unref (reply); BUS_SET_OOM (error); -- 2.17.0