bus: rework sd_bus_error APIs
authorLennart Poettering <lennart@poettering.net>
Fri, 22 Nov 2013 03:01:46 +0000 (04:01 +0100)
committerLennart Poettering <lennart@poettering.net>
Fri, 22 Nov 2013 03:23:22 +0000 (04:23 +0100)
commit780896a4f1ec7e36c8f72c866ba9693d790f9741
tree7aa9cf31a9ce94c729758b555433283056df3f39
parent6414b7c981378a6eef480f6806d7cbfc98ca22a1
bus: rework sd_bus_error APIs

All calls that set a sd_bus_error structure will now return the same
error converted to a negative errno. This may be used as syntactic sugar
to return from a function and setting a bus_error structure in one go.

Also, translate all Linux Exyz (EIO, EINVAL, EUCLEAN, EPIPE, ...)
automatically into counterparts in the (new) "Posix.Error." namespace.

If we fail to allocate memory for the components of a sd_bus_error
automatically reset it to an OOM error which we always can write.
Makefile.am
src/core/syscall-list.c
src/libsystemd-bus/bus-convenience.c
src/libsystemd-bus/bus-error.c
src/libsystemd-bus/bus-message.c
src/libsystemd-bus/test-bus-error.c [new file with mode: 0644]
src/shared/.gitignore [new file with mode: 0644]
src/shared/errno-list.c [new file with mode: 0644]
src/shared/errno-list.h [new file with mode: 0644]