summaryrefslogtreecommitdiffstats
path: root/src/monitor
diff options
context:
space:
mode:
authorFabiano Fidêncio <fidencio@redhat.com>2016-12-02 18:10:47 +0100
committerLukas Slebodnik <lslebodn@redhat.com>2017-01-23 18:46:37 +0100
commit7622d9d97eb6747a9f3406633281f2492f8f4a0a (patch)
tree6a798c3f4d34fb86871be3b87f80339456dcd9bd /src/monitor
parentb46c4c0d3e364636af1b42683cd3229ffa0b77cb (diff)
downloadsssd-7622d9d97eb6747a9f3406633281f2492f8f4a0a.tar.gz
sssd-7622d9d97eb6747a9f3406633281f2492f8f4a0a.tar.xz
sssd-7622d9d97eb6747a9f3406633281f2492f8f4a0a.zip
SBUS: Add destructor data to sbus_connection
This additions has a very specific reason: unregister a service when it's shutdown. So far, we never had to do this kind of operation because the services were started during SSSD's startup when finished when SSSD finished. Now, with the socket-activation in place the game will be a little bit different as the services will have an idle timeout and will be able shut themselves down. In order to do it properly the monitor will need to "unregister" the service and there's no way to do that without adding this destructor data to the sbus_connection structure and introducing a new function to access it from the monitor (where we're going to set the destructor function to the sbus_connection for the socket-activated services). So far it's not being used anywhere as every function taking it as parameter is just receiving NULL, but it will be used in the follow up commits, by the monitor. Related: https://fedorahosted.org/sssd/ticket/3245 Signed-off-by: Fabiano Fidêncio <fidencio@redhat.com> Reviewed-by: Pavel Březina <pbrezina@redhat.com> Reviewed-by: Jakub Hrozek <jhrozek@redhat.com> Reviewed-by: Lukáš Slebodník <lslebodn@redhat.com>
Diffstat (limited to 'src/monitor')
-rw-r--r--src/monitor/monitor.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/monitor/monitor.c b/src/monitor/monitor.c
index 30cd3f1a6..60b9dc2e0 100644
--- a/src/monitor/monitor.c
+++ b/src/monitor/monitor.c
@@ -644,7 +644,7 @@ static int monitor_dbus_init(struct mt_ctx *ctx)
* lose any access.
*/
ret = sbus_new_server(ctx, ctx->ev, monitor_address, ctx->uid, ctx->gid,
- false, &ctx->sbus_srv, monitor_service_init, ctx);
+ false, &ctx->sbus_srv, monitor_service_init, ctx, NULL);
talloc_free(monitor_address);