Date: Sun, 17 Mar 2013 21:38:39 -0700 From: "Myles C. Maxfield" <myles.maxfield@gmail.com> To: freebsd-ports-bugs@freebsd.org Subject: /dev/dspN detection in PulseAudio Message-ID: <CALz%2B48Uz4PiZy6OSo_BVP-DoOxZ3HhOkBj1gun24QPeoinmoww@mail.gmail.com>
next in thread | raw e-mail | index | archive | help
Hello, After upgrading to the latest stable version of FreeBSD (9.1), I noticed that some of my /dev/dspN devices had stopped showing up in PulseAudio. I took a look at the code for the detect_oss() function in src/modules/module-detect.c, and found that PulseAudio was discovering dsp devices by parsing /dev/sndstat. I recompiled pulseaudio with debugging symbols, and stepped through execution of the function. It turns out that when PulseAudio opens /dev/sndstat, it reads an empty line in the middle of the file, which was triggering the early-out of the loop (lines 151-152). If I removed those two early-out lines, then all my /dev/dspN devices are correctly recognized and everything works great. There is one caveat, however: When I cat /dev/sndstat from the command-line, there is no empty line in the middle of the file. At this point, I'm wondering if I should submit a patch to the PulseAudio port (/ports/head/audio/pulseaudio/files/patch-src_modules_module-detect.c), or if I should keep digging into why /dev/sndstat has an empty line in the middle of the file (but only when the file is read by PulseAudio). Does anyone have any suggestions on what I should do now? Thanks, Myles
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CALz%2B48Uz4PiZy6OSo_BVP-DoOxZ3HhOkBj1gun24QPeoinmoww>