pcm/ioplug: fix error code in start callback

When snd_pcm_start() is called in the invalid state, it should return
-EBADFD.  But ioplug plugin returns -EAGAIN.  Let's fix it.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
This commit is contained in:
Takashi Iwai 2009-08-21 01:34:29 +02:00
parent bd5389278c
commit cbf5675eef

View file

@ -442,7 +442,7 @@ static int snd_pcm_ioplug_start(snd_pcm_t *pcm)
int err;
if (io->data->state != SND_PCM_STATE_PREPARED)
return -EBUSY;
return -EBADFD;
err = io->data->callback->start(io->data);
if (err < 0)