chiark / gitweb /
sd-bus: fix parsing of KDBUS_CMD_LIST
authorDavid Herrmann <dh.herrmann@gmail.com>
Thu, 30 Jul 2015 12:12:09 +0000 (14:12 +0200)
committerSven Eden <yamakuzure@gmx.net>
Tue, 14 Mar 2017 09:07:20 +0000 (10:07 +0100)
commit9d4eda83cba98dc7ba5c920820f81dbf757e68d5
treee2b19552ee6232e237c9747fb8f940b1f01f5868
parent1131678bf7faf5b1ff992e4d1b5546e8d3e4ba5d
sd-bus: fix parsing of KDBUS_CMD_LIST

We *must not* assume that an entry returned by KDBUS_CMD_LIST only
carries a single KDBUS_ITEM_OWNED_NAME. Similarly, we already parse
multiple such items for message-metadata, so make sure we support the
same on KDBUS_CMD_LIST.

By relying on the kernel to return all names separately, we limit the
kernel API significantly. Stop this and let the kernel decide how to
return its data.
src/libelogind/sd-bus/bus-control.c