If there is an empty configuration file, D-Bus will fail to start.
On Gentoo, I do as such...
sudo touch /etc/dbus-1/system.d/foo.conf
sudo /etc/init.d/dbus restart
And the output I get is
Failed to start message bus: Not enough memory.
This also happens with Gentoo/FreeBSD.
Versions tested were .62, .91, .92, .93
Attempting to start with dbus-daemon --system --nofork also reports the same
CFLAGS used were
(0.62) - -march=pentium2 -O2 -fomit-frame-pointer -pipe -fforce-addr
(0.9x) - -march=pentium3 -O2 -pipe -fforce addr
-march=i686 -O2 -pipe
Not sure what all else info is required, simply ask and I am more than willing
Failed to start message bus: Error in file /etc/dbus-1/system.d/test.conf, line
1, column 0: no element found
which is correct, though we should most likely ignore this and send a warning
Unless I'm missing something I'd say NOTABUG - a config file is necessary to
define a bus daemon, there is no sensible default behavior. And the minimum
valid config file will have the root xml element, an empty file is not a valid
I would think a warning would be better than erroring. I don't know why Gentoo
reports it as Not enough memory - but I have had quite a few people test it, all
with the same results. It could be that checks are disabled in the ebuild, I
will look into that as well tomorrow, when my internet access is a bit more reliable
An error is required because there's no way to continue; the daemon doesn't
know what to do without a config file. It would not behave in any sensible way
(would not even know whether to fork or not)
I am leaning towards not a bug other than the fact that the gentoo guys are
getting out of memory errors which is not helpful in debugging the issue if it
were to come up. My reasoning for keeping the abort is we can not fix user or
packaging errors (would you propose we still run if someone overwrote
system.conf?). A malformed policy file could indicate larger problems and would
put the bus in an unkown state if the file itself should have had content in it.
committing as not a bug. Above states why.