diff options
| author | Carl Hetherington <cth@carlh.net> | 2020-09-25 21:03:23 +0200 |
|---|---|---|
| committer | Carl Hetherington <cth@carlh.net> | 2020-09-25 21:03:23 +0200 |
| commit | e98f84b69cc9e4e67667326194f14abe422978d2 (patch) | |
| tree | 14121034a670ee187abbe8b797306be91f78582c | |
| parent | 26a617e952a92ea178461166e638963d451a367d (diff) | |
Use the appropriate RtAudio exception (though I'm not sure if this
still necessary).
| -rw-r--r-- | src/wx/config_dialog.cc | 10 | ||||
| -rw-r--r-- | src/wx/film_viewer.cc | 4 |
2 files changed, 13 insertions, 1 deletions
diff --git a/src/wx/config_dialog.cc b/src/wx/config_dialog.cc index 7a4bb92c9..8eddeab4d 100644 --- a/src/wx/config_dialog.cc +++ b/src/wx/config_dialog.cc @@ -927,7 +927,11 @@ SoundPage::sound_output_changed () string default_device; try { default_device = audio.getDeviceInfo(audio.getDefaultOutputDevice()).name; +#ifdef DCPOMATIC_USE_RTERROR + } catch (RtError&) { +#else } catch (RtAudioError&) { +#endif /* Never mind */ } if (!so || *so == default_device) { @@ -954,7 +958,11 @@ SoundPage::config_changed () RtAudio audio (DCPOMATIC_RTAUDIO_API); try { configured_so = audio.getDeviceInfo(audio.getDefaultOutputDevice()).name; - } catch (RtAudioError& e) { +#ifdef DCPOMATIC_USE_RTERROR + } catch (RtError&) { +#else + } catch (RtAudioError&) { +#endif /* Probably no audio devices at all */ } } diff --git a/src/wx/film_viewer.cc b/src/wx/film_viewer.cc index 151b578cd..ff278d8a9 100644 --- a/src/wx/film_viewer.cc +++ b/src/wx/film_viewer.cc @@ -534,7 +534,11 @@ FilmViewer::config_changed (Config::Property p) if (_audio.getDeviceInfo(st).name == Config::instance()->sound_output().get()) { break; } +#ifdef DCPOMATIC_USE_RTERROR + } catch (RtError&) { +#else } catch (RtAudioError&) { +#endif /* Something went wrong with that device so we don't want to use it anyway */ } ++st; |
