Jens M Andreasen wrote:
> int err = snd_rawmidi_open(/*in*/NULL,/*out*/&handle_out,
> device,0);
>
> The code above will wait forever if the device is already taken.
> Opening the device with SND_RAWMIDI_NONBLOCK as last argument will get
> you past that point, but then the write operation may fail (returning
> negative) or return less bytes than you asked for to be written.
You can open the device with SND_RAWMIDI_NONBLOCK and then set it to
blocking mode with "snd_rawmidi_nonblock(handle_out, 0);".
HTH
Clemens
Received on Wed Jul 27 12:15:07 2005
This archive was generated by hypermail 2.1.8 : Wed Jul 27 2005 - 12:15:07 EEST