sd-bus: fix error handling on readv()
authorLennart Poettering <lennart@poettering.net>
Thu, 20 Aug 2020 10:59:23 +0000 (12:59 +0200)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Thu, 20 Aug 2020 12:14:36 +0000 (14:14 +0200)
commitc1093c34d7d81b5b13cc72d4d1941000813001da
tree2acb382df3f4bd5fdd1943c4d0e88a0bfba6080a
parent7489ccc350ad61006603d9c7156ac801054d4f10
sd-bus: fix error handling on readv()

let's make sure we collect the right error code from errno, otherwise
we'll see EPERM (i.e. error 1) for all errors readv() returns (since it
returns -1 on error), including EAGAIN.

This is definitely backport material.

A fix-up for 3691bcf3c5eebdcca5b4f1c51c745441c57a6cd1.

Fixes: #16699
src/libsystemd/sd-bus/bus-socket.c