diff options
-rw-r--r-- | gtk2_ardour/export_file_notebook.cc | 9 | ||||
-rw-r--r-- | libs/ardour/export_profile_manager.cc | 2 |
2 files changed, 9 insertions, 2 deletions
diff --git a/gtk2_ardour/export_file_notebook.cc b/gtk2_ardour/export_file_notebook.cc index 959bc42a2f..c9cd747d75 100644 --- a/gtk2_ardour/export_file_notebook.cc +++ b/gtk2_ardour/export_file_notebook.cc @@ -273,8 +273,13 @@ void ExportFileNotebook::FilePage::update_example_filename() { if (profile_manager) { - std::string example = profile_manager->get_sample_filename_for_format ( - filename_state->filename, format_state->format); + + std::string example; + if (format_state->format) { + example = profile_manager->get_sample_filename_for_format ( + filename_state->filename, format_state->format); + } + if (example != "") { sys::path path(example); filename_selector.set_example_filename(path.leaf()); diff --git a/libs/ardour/export_profile_manager.cc b/libs/ardour/export_profile_manager.cc index c644687f59..54779cfa32 100644 --- a/libs/ardour/export_profile_manager.cc +++ b/libs/ardour/export_profile_manager.cc @@ -714,6 +714,8 @@ ExportProfileManager::remove_filename_state (FilenameStatePtr state) std::string ExportProfileManager::get_sample_filename_for_format (ExportFilenamePtr filename, ExportFormatSpecPtr format) { + assert (format); + if (channel_configs.empty()) { return ""; } std::list<string> filenames; |