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
(parent:
879674e
)
bus-util: Fix reading uint32 properties
author
Martin Pitt
<martin.pitt@ubuntu.com>
Fri, 1 Apr 2016 12:16:14 +0000
(14:16 +0200)
committer
Sven Eden
<yamakuzure@gmx.net>
Fri, 16 Jun 2017 08:12:57 +0000
(10:12 +0200)
Fix copy&paste bug in map_basic() to use the correct data type for
SD_BUS_TYPE_UINT32. Before we were copying the wrong 32 bits into the
destination pointer, resulting in complete garbage on big-endian systems.
Fixes #2927
src/shared/bus-util.c
patch
|
blob
|
history
diff --git
a/src/shared/bus-util.c
b/src/shared/bus-util.c
index 02c0f3a79d143d716af20a7ef152a8854075e677..94872a31c4603377f707fd9d6967dcb1c1380d74 100644
(file)
--- a/
src/shared/bus-util.c
+++ b/
src/shared/bus-util.c
@@
-1072,7
+1072,7
@@
static int map_basic(sd_bus *bus, const char *member, sd_bus_message *m, sd_bus_
}
case SD_BUS_TYPE_UINT32: {
- uint
64
_t u;
+ uint
32
_t u;
uint32_t *p = userdata;
r = sd_bus_message_read_basic(m, type, &u);