to output ring buffer in the kernel space. This flag also means that device
is not opened exclusively, so more applications can share given rawmidi device.
Note that applications must send the whole MIDI message including the running status,
-because another writting application might break the MIDI message in the output
+because another writing application might break the MIDI message in the output
buffer.
\subsection rawmidi_open_sync Sync open (flag)
snd_config_delete(type_conf);
if (err >= 0)
err = open_func(inputp, outputp, name, rawmidi_root, rawmidi_conf, mode);
- if (err < 0)
+ if (err < 0) {
+ if (h)
+ snd_dlclose(h);
return err;
+ }
if (inputp) {
(*inputp)->dl_handle = h; h = NULL;
snd_rawmidi_params_default(*inputp, ¶ms);