mirror of
https://github.com/Ardour/ardour.git
synced 2026-01-06 21:55:43 +01:00
Fix MIDI disk-writer flush
to_write must not exceed `total = _samples_pending_write`. If the write succeeds (events spanning `to_write` samples are written) to_write is atomically subtracted from `_samples_pending_write`.
This commit is contained in:
parent
f15297e24c
commit
254f22e372
1 changed files with 1 additions and 1 deletions
|
|
@ -991,7 +991,7 @@ DiskWriter::do_flush (RunContext ctxt, bool force_flush)
|
|||
|
||||
if (force_flush) {
|
||||
/* push out everything we have, right now */
|
||||
to_write = UINT32_MAX;
|
||||
to_write = total;
|
||||
} else {
|
||||
to_write = _chunk_samples;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue