Fixed xfer variable initialization for capture in avail_update()

This commit is contained in:
Jaroslav Kysela 2002-02-21 15:03:50 +00:00
parent e128bf856e
commit 4a0e9058a9

View file

@ -496,11 +496,10 @@ snd_pcm_sframes_t snd_pcm_plugin_avail_update(snd_pcm_t *pcm)
const snd_pcm_channel_area_t *areas; const snd_pcm_channel_area_t *areas;
snd_pcm_uframes_t xfer, hw_offset, size; snd_pcm_uframes_t xfer, hw_offset, size;
size = snd_pcm_mmap_capture_avail(pcm); xfer = snd_pcm_mmap_capture_avail(pcm);
size = pcm->buffer_size - size; size = pcm->buffer_size - xfer;
areas = snd_pcm_mmap_areas(pcm); areas = snd_pcm_mmap_areas(pcm);
hw_offset = snd_pcm_mmap_hw_offset(pcm); hw_offset = snd_pcm_mmap_hw_offset(pcm);
xfer = 0;
while (size > 0 && slave_size > 0) { while (size > 0 && slave_size > 0) {
snd_pcm_uframes_t frames = size; snd_pcm_uframes_t frames = size;
snd_pcm_uframes_t cont = pcm->buffer_size - hw_offset; snd_pcm_uframes_t cont = pcm->buffer_size - hw_offset;