diff options
author | Chris Robinson <[email protected]> | 2009-09-27 03:57:19 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2009-09-27 03:57:19 -0700 |
commit | 1d54b7a266874aa39f36d3dd49ea209f519401e8 (patch) | |
tree | 3f73aecef6143539c7d557cf82eeee6b0fe0dddd /Alc/alsa.c | |
parent | c9506d939a10a79d887cb910a7935828765241af (diff) |
Fix capture, too
Diffstat (limited to 'Alc/alsa.c')
-rw-r--r-- | Alc/alsa.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -684,17 +684,17 @@ static ALCboolean alsa_open_capture(ALCdevice *pDevice, const ALCchar *deviceNam devName = allCaptureDevNameMap[idx].name; if(idx > 0) sprintf(driver, "plughw:%d,%d", allCaptureDevNameMap[idx].card, allCaptureDevNameMap[idx].dev); - goto open_alsa; + break; } } - return ALC_FALSE; + if(idx == numCaptureDevNames) + return ALC_FALSE; } alsa_load(); if(!alsa_handle) return ALC_FALSE; -open_alsa: data = (alsa_data*)calloc(1, sizeof(alsa_data)); i = psnd_pcm_open(&data->pcmHandle, driver, SND_PCM_STREAM_CAPTURE, SND_PCM_NONBLOCK); |