chiark
/
gitweb
/
~ianmdlvl
/
elogind.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(from parent 1:
77c1020
)
bus: fix bus_print_property() to use "int" for booleans
author
David Herrmann
<dh.herrmann@gmail.com>
Thu, 18 Sep 2014 11:28:28 +0000
(13:28 +0200)
committer
David Herrmann
<dh.herrmann@gmail.com>
Thu, 18 Sep 2014 11:57:13 +0000
(13:57 +0200)
We always use "int" if we retrieve boolean values from sd-bus, as "bool"
is only a single byte, but full int on va-args.
Thanks to Werner Fink for the report!
src/libsystemd/sd-bus/bus-util.c
patch
|
blob
|
history
diff --git
a/src/libsystemd/sd-bus/bus-util.c
b/src/libsystemd/sd-bus/bus-util.c
index 7c6da60ccabc9212287235dc4dcb6551dcd0f673..9018bcee5c32511ea20dd2aa45e408710f9c1f2a 100644
(file)
--- a/
src/libsystemd/sd-bus/bus-util.c
+++ b/
src/libsystemd/sd-bus/bus-util.c
@@
-631,7
+631,7
@@
int bus_print_property(const char *name, sd_bus_message *property, bool all) {
}
case SD_BUS_TYPE_BOOLEAN: {
-
bool
b;
+
int
b;
r = sd_bus_message_read_basic(property, type, &b);
if (r < 0)