Skip to contentSkip to conversation

pcm_native: fix sparse warning about shadowing 'state' symbol

PATCH New Marcin Ślusarz 1 participant 1 message Dec 8, 2007 Sound

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 pcm_native: fix sparse warning about shadowing 'state' symbol

pcm_native: fix sparse warning about shadowing 'state' symbol

---
 sound/core/pcm_native.c |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
sound/core/pcm_native.c +3 -3
index fb3dde4..925f0b6 100644
@@ -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;