chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Prep v231: Apply missing fixes from upstream (3/6) src/libelogind
[elogind.git]
/
src
/
libelogind
/
sd-bus
/
bus-match.c
diff --git
a/src/libelogind/sd-bus/bus-match.c
b/src/libelogind/sd-bus/bus-match.c
index 8ef30f55e74e16d43e19b0a06ca22e966b935167..3e6930a0d3de2c4ad989369336002e09e0b2bcfc 100644
(file)
--- a/
src/libelogind/sd-bus/bus-match.c
+++ b/
src/libelogind/sd-bus/bus-match.c
@@
-1,5
+1,3
@@
-/*-*- Mode: C; c-basic-offset: 8; indent-tabs-mode: nil -*-*/
-
/***
This file is part of systemd.
/***
This file is part of systemd.
@@
-19,10
+17,15
@@
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
along with systemd; If not, see <http://www.gnu.org/licenses/>.
***/
+#include "alloc-util.h"
#include "bus-internal.h"
#include "bus-internal.h"
-#include "bus-message.h"
#include "bus-match.h"
#include "bus-match.h"
+#include "bus-message.h"
#include "bus-util.h"
#include "bus-util.h"
+#include "fd-util.h"
+#include "fileio.h"
+#include "hexdecoct.h"
+#include "string-util.h"
#include "strv.h"
/* Example:
#include "strv.h"
/* Example:
@@
-312,7
+315,7
@@
int bus_match_run(
/* Run the callback. And then invoke siblings. */
if (node->leaf.callback->callback) {
/* Run the callback. And then invoke siblings. */
if (node->leaf.callback->callback) {
- _cleanup_
bus_error_free_
sd_bus_error error_buffer = SD_BUS_ERROR_NULL;
+ _cleanup_
(sd_bus_error_free)
sd_bus_error error_buffer = SD_BUS_ERROR_NULL;
sd_bus_slot *slot;
slot = container_of(node->leaf.callback, sd_bus_slot, match_callback);
sd_bus_slot *slot;
slot = container_of(node->leaf.callback, sd_bus_slot, match_callback);
@@
-426,6
+429,9
@@
int bus_match_run(
r = bus_match_run(bus, c, m);
if (r != 0)
return r;
r = bus_match_run(bus, c, m);
if (r != 0)
return r;
+
+ if (bus && bus->match_callbacks_modified)
+ return 0;
}
}
}
}
@@
-931,13
+937,13
@@
fail:
return r;
}
return r;
}
-/// UNNEEDED by elogind
-#if 0
+#if 0 /// UNNEEDED by elogind
char *bus_match_to_string(struct bus_match_component *components, unsigned n_components) {
char *bus_match_to_string(struct bus_match_component *components, unsigned n_components) {
- _cleanup_f
re
e_ FILE *f = NULL;
+ _cleanup_f
clos
e_ FILE *f = NULL;
char *buffer = NULL;
size_t size = 0;
unsigned i;
char *buffer = NULL;
size_t size = 0;
unsigned i;
+ int r;
if (n_components <= 0)
return strdup("");
if (n_components <= 0)
return strdup("");