Skip to content

Draft: bus: When logging errors or warnings about config files, show location

Simon McVittie requested to merge smcv/dbus:config-error-location into master

Based on !418.

Needs a better commit/MR description, but for now, here's a preview:

$ ${builddir}/bus/dbus-daemon --config-file $(pwd)/foo.conf
dbus-daemon[256587]: /home/smcv/src/dbus/foo.conf:3:0: Ignoring <policy>: Looking up user "no-such-user": not found
dbus-daemon[256587]: /home/smcv/src/dbus/foo.conf:4:0: Ignoring <policy>: Group no-such-group unknown or failed to look it up

dbus-daemon[256587]: /home/smcv/src/dbus/foo.conf:6:0: Ignoring element <allow>: Looking up user "not-this-user": not found
dbus-daemon[256587]: /home/smcv/src/dbus/foo.conf:7:0: Ignoring element <deny>: (null)
dbus-daemon[256587]: Failed to start message bus: Unknown address type 'nope'

Merge request reports