]> git.ipfire.org Git - thirdparty/systemd.git/commit
sysupdated: Register known error types
authorAdrian Vovk <adrianvovk@gmail.com>
Sat, 31 Aug 2024 01:43:44 +0000 (21:43 -0400)
committerAdrian Vovk <adrianvovk@gmail.com>
Sat, 31 Aug 2024 01:43:44 +0000 (21:43 -0400)
commitaa2e664e1861e8874c8ead61419d1ea057b92ceb
tree144fda2988b28e545b11f1813c7c722a6ffbbf93
parent6e1992166f9a5ef282354bed1109f4ddb3f8267a
sysupdated: Register known error types

This fixes a bug introduced during review of sysupdated. Originally,
we just returned EALREADY verbatim to signify that the target is
already up-to-date. Then we switched this to a proper error
(org.freedesktop.sysupdate1.NoCandidate) during review. But that now
maps to EIO, not EALREADY. Thus, whenever there's nothing to update,
updatectl would report I/O errors to the user, even though nothing
actually went wrong.
src/libsystemd/sd-bus/bus-common-errors.c
src/libsystemd/sd-bus/bus-common-errors.h
src/sysupdate/sysupdated.c