monitor: use the addressed_recipient to select matches
authorSimon McVittie <smcv@collabora.com>
Mon, 25 Sep 2017 13:57:38 +0000 (14:57 +0100)
committerSimon McVittie <smcv@collabora.com>
Mon, 25 Sep 2017 15:20:08 +0000 (16:20 +0100)
commitcc9bc56aa33b2901e63c16d10af80cd4e3c52237
tree960a78b50c3dc9c82cfcb23e47e0507d2fa67805
parent4a2e702468172b80199d7f14010d27321512356c
monitor: use the addressed_recipient to select matches

This means we respect the destination keyword in arguments to
BecomeMonitor.

In bus_dispatch(), this means that we need to defer capturing until
we have decided whether there is an addressed recipient; so instead
of capturing once, we capture at each leaf of the decision tree.

Bug: https://bugs.freedesktop.org/show_bug.cgi?id=92074
Reviewed-by: Philip Withnall <philip.withnall@collabora.co.uk>
Reviewed-by: Lars Uebernickel <lars@uebernic.de>
(cherry picked from commit f3be583b40dadfd78ddefbc9fb3fa182bafde949)
Signed-off-by: Simon McVittie <smcv@collabora.com>
bus/activation.c
bus/connection.c
bus/connection.h
bus/dispatch.c
bus/driver.c
bus/signals.c
test/monitor.c