From 8dde26da7b57ae9dee7858e481605613098db59b Mon Sep 17 00:00:00 2001 From: David Robillard Date: Tue, 18 Nov 2014 02:29:50 -0500 Subject: Gracefully avoid importing audio that somehow has 0 channels. --- libs/ardour/import.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'libs/ardour/import.cc') diff --git a/libs/ardour/import.cc b/libs/ardour/import.cc index 656e8f7f76..ae5f751767 100644 --- a/libs/ardour/import.cc +++ b/libs/ardour/import.cc @@ -234,7 +234,9 @@ write_audio_data_to_new_files (ImportableSource* source, ImportStatus& status, const framecnt_t nframes = ResampledImportableSource::blocksize; boost::shared_ptr afs; uint32_t channels = source->channels(); - assert(channels > 0); + if (channels == 0) { + return; + } boost::scoped_array data(new float[nframes * channels]); vector > channel_data; -- cgit v1.2.3