Skip to contentSkip to conversation

short writes?

DISCUSSION william estrada 2 participants 2 messages Sep 30, 2007

lore
Share & tools
lore
#0 lore raw

Hi group,

I have written my own ALSA recorder and player. Along with that I have
several bugs. The bug I am working on right now is 'short writes' when I use the pipe command into my player. My player runs and asks for the file to play, so that I may play incoming files as they are sent in. I have a program that uses 'inotify' to watch for incoming file and then pipe the file name into my player.

Now with all of that, is there a API call that will put the writei into
blocking mode? Or an API call that will flush the output from writei? Or any other suggestions?

Thanks for your time.

Signature · 4 lines
William Estrada
[email protected]
Mt-Umunhum-Wireless.net ( http://Mt-Umunhum-Wireless.net )
Ymessenger: MrUmunhum
#1 lore raw
Quoted 2 lines · On Sun, 30 Sep 2007 11:47:37 -0700 william estrada <[email protected]>…

Now with all of that, is there a API call that will put the writei into
blocking mode?

snd_pcm_nonblock (pcm_handle, 0) ?

Quoted 1 line

Or an API call that will flush the output from writei?

snd_pcm_drain (pcm_handle) ?