diff options
author | Lennart Poettering <lennart@poettering.net> | 2014-12-06 02:39:15 +0100 |
---|---|---|
committer | Lennart Poettering <lennart@poettering.net> | 2014-12-08 14:55:22 +0100 |
commit | 5f86c1f4c43ee9caa120d130e9b89d3fd25124c0 (patch) | |
tree | 34908816bfd429ba578f99626eb2deabc1ed631a /src/timedate | |
parent | 8b5e2af10830d55b2032e6c79d0cd1f959bb5b7f (diff) |
sd-bus: rework ELF error mapping table magic
The ELF magic cannot work for consumers of our shard library, since they
are in a different module. Hence make all the ELF magic private, and
instead introduce a public function to register additional static
mapping table.
Diffstat (limited to 'src/timedate')
-rw-r--r-- | src/timedate/timedated.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/timedate/timedated.c b/src/timedate/timedated.c index 24de21008f..08ddc52ca6 100644 --- a/src/timedate/timedated.c +++ b/src/timedate/timedated.c @@ -38,14 +38,16 @@ #include "fileio-label.h" #include "label.h" #include "bus-util.h" +#include "bus-error.h" #include "bus-errors.h" #include "event-util.h" #define NULL_ADJTIME_UTC "0.0 0 0\n0\nUTC\n" #define NULL_ADJTIME_LOCAL "0.0 0 0\n0\nLOCAL\n" -SD_BUS_ERROR_MAPPING(timedated) = { - {"org.freedesktop.timedate1.NoNTPSupport", ENOTSUP}, +static BUS_ERROR_MAP_ELF_REGISTER const sd_bus_error_map timedated_errors[] = { + SD_BUS_ERROR_MAP("org.freedesktop.timedate1.NoNTPSupport", ENOTSUP), + SD_BUS_ERROR_MAP_END }; typedef struct Context { |