summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Mack <daniel@zonque.org>2015-02-13 14:55:51 +0100
committerDaniel Mack <daniel@zonque.org>2015-02-13 14:55:51 +0100
commit403193f54b6ff0d3e822d56d7144cf996a596146 (patch)
treefe9e84058583b20952f4a7eeda798cb852d3aafb
parent7d5fed66a6fd5731da7564ae47a9f693fa75a549 (diff)
sd-bus: sync kdbus.h (ABI break)
Another slice logic rework in kdbus made KDBUS_ITEM_PAYLOAD_OFF items relative to the message header again. Catch up with that in sd-bus.
-rw-r--r--src/libsystemd/sd-bus/bus-kernel.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/libsystemd/sd-bus/bus-kernel.c b/src/libsystemd/sd-bus/bus-kernel.c
index b884074d95..bdc770600b 100644
--- a/src/libsystemd/sd-bus/bus-kernel.c
+++ b/src/libsystemd/sd-bus/bus-kernel.c
@@ -434,7 +434,7 @@ static int bus_kernel_make_message(sd_bus *bus, struct kdbus_msg *k) {
case KDBUS_ITEM_PAYLOAD_OFF:
if (!h) {
- h = (struct bus_header *)((uint8_t *)bus->kdbus_buffer + d->vec.offset);
+ h = (struct bus_header *)((uint8_t *)k + d->vec.offset);
if (!bus_header_is_complete(h, d->vec.size))
return -EBADMSG;
@@ -526,11 +526,11 @@ static int bus_kernel_make_message(sd_bus *bus, struct kdbus_msg *k) {
if (idx >= begin_body) {
if (!part->is_zero)
- part->data = (uint8_t *)bus->kdbus_buffer + d->vec.offset;
+ part->data = (uint8_t *)k + d->vec.offset;
part->size = d->vec.size;
} else {
if (!part->is_zero)
- part->data = (uint8_t *)bus->kdbus_buffer + d->vec.offset + (begin_body - idx);
+ part->data = (uint8_t *)k + d->vec.offset + (begin_body - idx);
part->size = d->vec.size - (begin_body - idx);
}