diff options
author | Paul Davis <paul@linuxaudiosystems.com> | 2017-10-02 12:41:42 -0400 |
---|---|---|
committer | Paul Davis <paul@linuxaudiosystems.com> | 2017-10-02 12:44:52 -0400 |
commit | 7921f6dc4d59f31d111afaf2150d1be128818b22 (patch) | |
tree | 8791a097da7001c7661d4e64e95032c34c42fad5 /libs/ardour/disk_reader.cc | |
parent | 4cc5958960a435f85232bfa59a9a39fbd28fe4b3 (diff) |
DiskReader should do nothing at all if there are no channels
Diffstat (limited to 'libs/ardour/disk_reader.cc')
-rw-r--r-- | libs/ardour/disk_reader.cc | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/libs/ardour/disk_reader.cc b/libs/ardour/disk_reader.cc index 4c2ff1e2c1..4c5667b9db 100644 --- a/libs/ardour/disk_reader.cc +++ b/libs/ardour/disk_reader.cc @@ -251,12 +251,14 @@ DiskReader::run (BufferSet& bufs, samplepos_t start_sample, samplepos_t end_samp } } - if (speed == 0.0) { - /* Nothing to do here. - * - * Do not clear input buffers here when (ms == MonitoringDisk) - * we need to allow out-of-band data to pass thru from the input. - * (e.g. MIDI immediate events) + if (c->empty()) { + /* do nothing */ + return; + } + + if ((speed == 0.0) && (ms == MonitoringDisk)) { + /* no channels, or stopped. Don't accidentally pass any data + * from disk into our outputs (e.g. via interpolation) */ return; } |