Comment 6 for bug 557016

Revision history for this message
Danny Sauer (ubuntu-dannysauer) wrote :

That's an interesting theory, Raymond, but it ignores the fact that the state file is created/modified as expected, as noted in the following quote from post #4. :)

"In either case - with or without DISPLAY existing - the asound.state file is actually created."

Specifically:
 sauer@hotrod:~$ ls -l /var/lib/alsa/asound.state
 -rw-r--r-- 1 root root 10059 2010-11-02 22:03 /var/lib/alsa/asound.state
 sauer@hotrod:~$ sudo -i alsactl store
 X11 connection rejected because of wrong authentication.
 XOpenDisplay() failed
 sauer@hotrod:~$ ls -l /var/lib/alsa/asound.state
 -rw-r--r-- 1 root root 10059 2010-11-02 22:04 /var/lib/alsa/asound.state
 sauer@hotrod:~$ unset DISPLAY
 sauer@hotrod:~$ sudo -i alsactl store
 sauer@hotrod:~$ ls -l /var/lib/alsa/asound.state
 -rw-r--r-- 1 root root 10059 2010-11-02 22:05 /var/lib/alsa/asound.state

Note that the timestamp on the files changes each time (I waited a minute or so between runs). If I couldn't write to the file, I'd instead get this message:

 alsactl: save_state:1530: Cannot open /var/lib/alsa/asound.state for writing: Permission denied

All that's really wrong is that an error is generated by pulse, but the error doesn't actually matter for anything because everything actually works just fine. Well, except for emitting of an ignorable error message; even the return code is still 0. ;)

 sauer@hotrod:~$ sudo -i alsactl store; echo $?
 X11 connection rejected because of wrong authentication.
 XOpenDisplay() failed
 0

So this is properly categorized with importance of "wishlist". IMHO.