Hi All, I was hoping to get some advice on the proper use of Alsalib within Wine, particularly with respect to device detection and enumeration. Wine has a need to provide a list of all available PCM (playback and capture) devices back to our clients (a Windows program). Right now, Wine has a brute force scan process (iterate 0-5 in cards, always use dev 0). I've implemented a program that represents what I think is the 'right' way for Wine to perform this scan. Note that this code is just for the default case where the user hasn't explicitly specified a device name; Wine will still allow the user to override this scan with an explicit device name such as file:/tmp/blat The basic approach I take is as follows: Use snd_card_next to iterate cards; within cards, use snd_ctl_pcm_next_device to iterate devices. I jump through a few hoops to detect and respect a specification of ALSA_CTL_CARD or ALSA_CARD, etc, Now I've deluded myself into thinking this is a careful, rigorous implementation. Thoughts? Comments? Tactfully worded puncturing of my delusions ? Thanks, Jeremy