pulseaudio daemon won't start if ~/.config/pulse/default.pa is non-empty
Originally reported as https://bugzilla.redhat.com/show_bug.cgi?id=1479998
Description of problem:
After upgrading to Fedora 26 my KDE Plasma desktop had no audio devices available. This turned out to be because the pulseaudio daemon would not start, writing this to the journal:
Aug 09 17:42:50 wraith.home pulseaudio[6869]: [pulseaudio] main.c: Module module-switch-on-port-available not loaded.
Aug 09 17:42:50 wraith.home pulseaudio[6869]: [pulseaudio] main.c: Failed to initialize daemon.
Aug 09 17:42:50 wraith.home pulseaudio[6866]: [pulseaudio] main.c: Daemon startup failed.
Under Fedora 24 I had disabled that module with a per-user config file:
$ cat ~/.config/pulse/default.pa
unload-module module-switch-on-port-available
This config caused the daemon to exit on startup.
The daemon would not start even if the file only contains comments or empty lines.
The daemon only starts if the file is empty, or doesn't exist at all.
Version-Release number of selected component (if applicable):
pulseaudio-10.0-4.fc26.x86_64
How reproducible: Always
Steps to Reproduce:
pulseaudio --kill
echo > ~/config/pulse/default.pa
pulseaudio --start
Actual results:
E: [pulseaudio] main.c: Daemon startup failed.
Expected results: Daemon starts successfully.
The problem is still present in pulseaudio-11.1-15.fc27
and pulseaudio-12.2-1.fc29
.