From: Marcin Ślusarz Date: Fri, 14 Dec 2007 11:50:16 +0000 (+0100) Subject: [ALSA] pcm_native: fix sparse warning about shadowing 'state' symbol X-Git-Tag: v2.6.25-rc1~1127^2~194 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=b05e578740b5e58b729857321048c4babb24bf2b;p=linux-2.6-omap-h63xx.git [ALSA] pcm_native: fix sparse warning about shadowing 'state' symbol pcm_native: fix sparse warning about shadowing 'state' symbol Signed-off-by: Marcin Ślusarz Signed-off-by: Takashi Iwai Signed-off-by: Jaroslav Kysela --- diff --git a/sound/core/pcm_native.c b/sound/core/pcm_native.c index 51294dd3a7a..7fb7c921b27 100644 --- a/sound/core/pcm_native.c +++ b/sound/core/pcm_native.c @@ -1395,10 +1395,10 @@ static int snd_pcm_do_drain_init(struct snd_pcm_substream *substream, int state) } else { /* stop running stream */ if (runtime->status->state == SNDRV_PCM_STATE_RUNNING) { - int state = snd_pcm_capture_avail(runtime) > 0 ? + int new_state = snd_pcm_capture_avail(runtime) > 0 ? SNDRV_PCM_STATE_DRAINING : SNDRV_PCM_STATE_SETUP; - snd_pcm_do_stop(substream, state); - snd_pcm_post_stop(substream, state); + snd_pcm_do_stop(substream, new_state); + snd_pcm_post_stop(substream, new_state); } } return 0;