chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
sd-bus: deal with whitespace in matches
[elogind.git]
/
src
/
libsystemd
/
sd-bus
/
bus-match.c
diff --git
a/src/libsystemd/sd-bus/bus-match.c
b/src/libsystemd/sd-bus/bus-match.c
index 5658c61ba789fba1529c99112bb4be8159f90b69..0e92a85ef756fdaf177e8abdcf9c61394c5531dc 100644
(file)
--- a/
src/libsystemd/sd-bus/bus-match.c
+++ b/
src/libsystemd/sd-bus/bus-match.c
@@
-748,6
+748,9
@@
int bus_match_parse(
bool escaped = false, quoted;
uint8_t u;
bool escaped = false, quoted;
uint8_t u;
+ /* Avahi's match rules appear to include whitespace, skip over it */
+ p += strspn(p, " ");
+
eq = strchr(p, '=');
if (!eq)
return -EINVAL;
eq = strchr(p, '=');
if (!eq)
return -EINVAL;