[alsa-devel] snd_pcm_writei() return value

Clemens Ladisch clemens at ladisch.de
Mon May 25 09:49:04 CEST 2009

Cristian Morales Vega wrote:
> But if an interrupt happened, it could be that some samples were
> written and others no, true? If only -EINTR is returned, how I know
> how many of them I still need to write?

If any samples have been written successfully, snd_pcm_writei() returns
that number of samples.  You get a negative result only if no samples
have been written.


More information about the Alsa-devel mailing list